a7e59a00f8
The mode select in the topbar posted with hx-post against a route that only answers PATCH, so every change returned 405 and the mode never moved. htmx shows nothing when a request fails, so the control looked like it worked: the select stayed where you put it and the server ignored you. It has never worked. Two more of the same kind. A mode could not be chosen at all until the chat existed, so reaching Plan meant sending something in Manual first and letting the model answer under the wrong rules. And the project directory box was real and submitted, but unlabelled and squeezed to a few characters by the select beside it, so it read as broken -- which is how it was reported. So the kind, the connection, the directory and the mode move out of the strip above the text and into one toolbar row beneath it, where attach and send already are. The directory becomes a button that opens a browser over SFTP, because a path is something you would rather find than spell. `scan_dir` is new beside `list_dir`: a picker has to tell a directory from a file before it can draw the row, and `list_dir` backs a tool whose contract is a list of names and must not change under a model mid-conversation. Browsing is a person clicking, not a model calling, so it does not pass through policy.py -- the same argument the terminal panel rests on. It does mean Manual mode has a second exception now. Also: .chip was two components with one name, and the attachment card won, so the Chat/Agent pills silently wore its padding. --radius-md was used twice and declared nowhere, so both fell back to 0. .btn.is-active has been set by syncToggles since the terminal landed and styled by nothing. Enter-to-send ignored isComposing, so committing an IME candidate sent the message. The terminal had five colours of a sixteen-colour palette, with fallbacks from a palette that no longer exists. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
81 lines
2.5 KiB
TOML
81 lines
2.5 KiB
TOML
[build-system]
|
|
requires = ["hatchling"]
|
|
build-backend = "hatchling.build"
|
|
|
|
[project]
|
|
name = "lembas"
|
|
version = "0.6.0"
|
|
description = "LLeMbas - a Middle-earth themed web UI for OpenAI-compatible LLM endpoints"
|
|
readme = "README.md"
|
|
requires-python = ">=3.11"
|
|
license = { file = "LICENSE" }
|
|
authors = [{ name = "Jaroslav Benes", email = "admin@ecoposta.sk" }]
|
|
keywords = ["llm", "webui", "openai", "chat", "self-hosted"]
|
|
classifiers = [
|
|
"License :: OSI Approved :: GNU General Public License v3 (GPLv3)",
|
|
"Programming Language :: Python :: 3",
|
|
"Topic :: Communications :: Chat",
|
|
]
|
|
|
|
dependencies = [
|
|
"fastapi>=0.115",
|
|
"uvicorn[standard]>=0.32",
|
|
"jinja2>=3.1",
|
|
"sqlalchemy>=2.0",
|
|
"pydantic>=2.9",
|
|
"pydantic-settings>=2.6",
|
|
"httpx>=0.27",
|
|
"python-multipart>=0.0.12",
|
|
"argon2-cffi>=23.1",
|
|
"cryptography>=43.0",
|
|
"markdown-it-py>=3.0",
|
|
"mdit-py-plugins>=0.4",
|
|
"linkify-it-py>=2.0", # bare URLs in model output become links
|
|
"pygments>=2.18",
|
|
"nh3>=0.2.18",
|
|
"pypdf>=5.1", # PDF text extraction for attachments
|
|
"pillow>=11.0", # image validation and downscaling for vision
|
|
"typer>=0.12",
|
|
]
|
|
|
|
[project.optional-dependencies]
|
|
dev = [
|
|
"pytest>=8.3",
|
|
"pytest-asyncio>=0.24",
|
|
"ruff>=0.7",
|
|
]
|
|
# DuckDuckGo search. Optional because it brings a compiled HTTP client and an
|
|
# XML parser with it, and the other two search providers need only httpx, which
|
|
# is already a core dependency. Without this the provider is offered in the
|
|
# admin UI with an install hint rather than silently missing.
|
|
search = ["ddgs>=9.0"]
|
|
# Agent chats, which run their commands on a machine reached over SSH. Optional
|
|
# on the same terms as `search`: an instance that never turns agents on should
|
|
# not carry the dependency, and one that does gets told how to install it rather
|
|
# than finding the feature silently missing. `bcrypt` is what decrypts a
|
|
# passphrase-protected OpenSSH key -- without it, pasting one fails opaquely.
|
|
ssh = ["asyncssh[bcrypt]>=2.14"]
|
|
|
|
[project.scripts]
|
|
lembas = "lembas.cli:app"
|
|
|
|
[project.urls]
|
|
Homepage = "https://github.com/homer/LLeMbas"
|
|
|
|
[tool.hatch.build.targets.wheel]
|
|
packages = ["src/lembas"]
|
|
|
|
[tool.ruff]
|
|
line-length = 100
|
|
target-version = "py311"
|
|
src = ["src", "tests"]
|
|
|
|
[tool.ruff.lint]
|
|
select = ["E", "F", "I", "UP", "B", "SIM", "C4"]
|
|
ignore = ["B008"] # FastAPI Depends() in defaults is idiomatic
|
|
|
|
[tool.pytest.ini_options]
|
|
testpaths = ["tests"]
|
|
asyncio_mode = "auto"
|
|
filterwarnings = ["ignore::DeprecationWarning"]
|