forked from enderofwings/NexusOS
Reconciles 17 commits of this session's work (self-alteration tools, vendored Curry, slash-command dispatch, Windows toolchain/gate fixes) against origin/main's v1.2.0 sync (Projects/RAG scoping, a new modules/ system for mail and network, in-app updates, the standalone memory microservice folded into an in-process curator, KDE desktop theme overhaul). Nine real conflicts, each resolved by hand after reading both sides' actual diffs rather than picking one side wholesale: - synapse/tools.py, tests/test_tools.py: origin/main's diff here was small and clean (read_file/list_files, two new tests) despite git's diff3 flagging the whole file as one conflict blob -- reset to this branch's version and hand-spliced their addition in at the same points they used, rather than trying to reconcile a false 800-line conflict. Found and fixed a real bug while verifying: _list_files returned backslash-separated paths on Windows, which don't match the forward-slash glob patterns the tool's own schema documents. - synapse/main.py: kept this branch's cue-based standing advertisement of render_preview/run_snippet (independent of any playbook granting them) AND adopted origin/main's fix for routed reference playbooks not bringing their own tools along -- dropping either would have been a real regression, not just a style difference. Also: the standalone memory service (port 8001) is gone upstream, so its dead CORS/kill- target entries were removed; NEXUS_BACKEND_PORT parameterization and the manage_ollama-conditional kill logic (this branch's remote-Ollama support) were kept over origin/main's hardcoded equivalents. - synapse/memory/store.py: kept this branch's _delete_message_vectors helper (already reused elsewhere, batches to stay under SQLite's variable limit) over origin/main's inline duplicate of the same fix. - synapse/nexus_config.py, nexusos_cli/ncp.py: dropped the now-dead memory-service port/service entries; kept NEXUS_BACKEND_PORT env override and the manage_ollama-conditional kill-target list. - CLAUDE.md, README.md: merged both sides' additions, no real conflict. Found and fixed three more issues while independently verifying the merged tree, none of them mine or origin/main's alone -- only visible once both sides actually ran together: - modules/ (the new mail+network package) was never added to pyproject.toml's wheel `packages` list OR the sdist's `include` allowlist, so `from modules.registry import ROUTERS` in main.py would ImportError on any wheel install. Fixed both; bin/check.sh's packaging gate now asserts modules/ actually ships. tests/ test_packaging_deps.py's FIRST_PARTY/SHIPPED_PACKAGES sets were updated to recognize the new package. - tests/test_mail_creds.py's 0600-mode assertions are POSIX-only -- NTFS has no equivalent permission bits, so os.open(path, 0o600) on Windows just creates a normal file and stat.S_IMODE reports 0o666 regardless. Made the assertions platform-aware rather than skip real coverage (the temp-file-cleanup and password round-trip checks in the same test still run on Windows) or paper over a genuine OS limitation with a fake pass. - tests/test_kde_theme.py used bare Path.read_text() in fifteen places; Windows' default locale encoding (cp1252, not UTF-8) can't decode a real UTF-8 byte in the QML it reads, and did fail on one of the fifteen. Fixed all fifteen, not just the one that happened to trip today, since the other fourteen were equally fragile. Verified: full bin/check.sh reports OK end-to-end on this Windows checkout -- pytest (tests + management): 295 passed, 0 failed, 9 skipped; eslint clean; frontend node:test 57/57; PowerShell/shell parse clean; wheel + sdist pass twine check and now correctly carry modules/ (60 files, up from 52 pre-merge). synapse.main:app builds with 74 routes (up from 54 pre-merge, matching the new Projects/mail/ network endpoints).
131 lines
3.7 KiB
TOML
131 lines
3.7 KiB
TOML
[build-system]
|
|
requires = ["hatchling>=1.26"]
|
|
build-backend = "hatchling.build"
|
|
|
|
[project]
|
|
name = "nexusos-ai"
|
|
dynamic = ["version"]
|
|
description = "Local-first AI assistant runtime, web UI, and portable CLI"
|
|
readme = "README.md"
|
|
requires-python = ">=3.11"
|
|
authors = [{name = "EnderOfWings"}]
|
|
keywords = ["ai", "assistant", "ollama", "local-ai", "termux"]
|
|
classifiers = [
|
|
"Development Status :: 4 - Beta",
|
|
"Environment :: Console",
|
|
"Framework :: FastAPI",
|
|
"Operating System :: Android",
|
|
"Operating System :: Microsoft :: Windows",
|
|
"Operating System :: POSIX :: Linux",
|
|
"Programming Language :: Python :: 3",
|
|
"Programming Language :: Python :: 3.11",
|
|
"Programming Language :: Python :: 3.12",
|
|
"Programming Language :: Python :: 3.13",
|
|
"Programming Language :: Python :: 3.14",
|
|
"Topic :: Communications :: Chat",
|
|
]
|
|
dependencies = [
|
|
"fastapi>=0.115,<1",
|
|
"httpx>=0.27,<1",
|
|
"pydantic>=2.7,<3",
|
|
"python-dotenv>=1,<2",
|
|
"PyYAML>=6,<7",
|
|
"uvicorn>=0.30,<1",
|
|
]
|
|
|
|
[project.optional-dependencies]
|
|
documents = ["pypdf>=5,<7", "python-docx>=1.1,<2"]
|
|
process = ["psutil>=5.9,<8"]
|
|
vector = ["sqlite-vec>=0.1,<1"]
|
|
voice = ["faster-whisper>=1.1,<2"]
|
|
mail = ["imap-tools>=1.7,<2"]
|
|
# synapse/search.py imports this lazily behind a bare except, so without it
|
|
# declared the chat web-search path silently returns nothing.
|
|
search = ["duckduckgo-search>=6,<9"]
|
|
tui = ["textual>=1.0,<3"]
|
|
desktop = [
|
|
"psutil>=5.9,<8",
|
|
"pywebview>=5,<7; platform_system == 'Windows'",
|
|
]
|
|
standard = [
|
|
"pypdf>=5,<7",
|
|
"python-docx>=1.1,<2",
|
|
"psutil>=5.9,<8",
|
|
"sqlite-vec>=0.1,<1",
|
|
"duckduckgo-search>=6,<9",
|
|
]
|
|
# Every optional capability at once. Kept in sync with the extras above by
|
|
# tests/test_packaging_deps.py, which also checks that nothing synapse imports
|
|
# is missing from this file.
|
|
all = [
|
|
"pypdf>=5,<7",
|
|
"python-docx>=1.1,<2",
|
|
"psutil>=5.9,<8",
|
|
"sqlite-vec>=0.1,<1",
|
|
"faster-whisper>=1.1,<2",
|
|
"imap-tools>=1.7,<2",
|
|
"duckduckgo-search>=6,<9",
|
|
"textual>=1.0,<3",
|
|
"pywebview>=5,<7; platform_system == 'Windows'",
|
|
]
|
|
dev = [
|
|
"build>=1.2,<2",
|
|
"pytest>=8,<10",
|
|
"twine>=7,<8",
|
|
]
|
|
|
|
[project.scripts]
|
|
nexus = "nexusos_cli.cli:entrypoint"
|
|
ncp = "nexusos_cli.cli:entrypoint"
|
|
nexusos = "nexusos_cli.cli:entrypoint"
|
|
|
|
[project.urls]
|
|
Homepage = "https://git.enderofwings.com/enderofwings/NexusOS"
|
|
Issues = "https://git.enderofwings.com/enderofwings/NexusOS/issues"
|
|
Repository = "https://git.enderofwings.com/enderofwings/NexusOS"
|
|
|
|
[tool.hatch.version]
|
|
path = "VERSION"
|
|
pattern = "^(?P<version>[^\\s]+)$"
|
|
|
|
[tool.hatch.build]
|
|
skip-excluded-dirs = true
|
|
|
|
# Ships interface/web/dist when it has been built. It is gitignored, so a
|
|
# static force-include would abort `pip install -e .` on a fresh clone.
|
|
[tool.hatch.build.hooks.custom]
|
|
path = "hatch_build.py"
|
|
|
|
[tool.hatch.build.targets.wheel]
|
|
packages = ["synapse", "nexusos_cli", "modules"]
|
|
|
|
[tool.hatch.build.targets.wheel.force-include]
|
|
"VERSION" = "synapse/_resources/VERSION"
|
|
"data/playbooks" = "synapse/_resources/playbooks"
|
|
"assets/n-small.png" = "synapse/_resources/assets/n-small.png"
|
|
"assets/themes/NexusOS-icons-src/nexus-underlay.svg" = "synapse/_resources/assets/themes/NexusOS-icons-src/nexus-underlay.svg"
|
|
"assets/themes/NexusOS-icons-src/nexus-underlay-ring.svg" = "synapse/_resources/assets/themes/NexusOS-icons-src/nexus-underlay-ring.svg"
|
|
|
|
[tool.hatch.build.targets.sdist]
|
|
include = [
|
|
"/assets/n-small.png",
|
|
"/assets/themes/NexusOS-icons-src/nexus-underlay.svg",
|
|
"/assets/themes/NexusOS-icons-src/nexus-underlay-ring.svg",
|
|
"/data/playbooks",
|
|
"/docs",
|
|
"/management",
|
|
"/modules",
|
|
"/nexusos_cli",
|
|
"/scripts",
|
|
"/synapse",
|
|
"/tests",
|
|
"/README.md",
|
|
"/VERSION",
|
|
"/pyproject.toml",
|
|
"/hatch_build.py",
|
|
]
|
|
|
|
|
|
[tool.pytest.ini_options]
|
|
testpaths = ["tests", "management"]
|