ollajev 0.2.0__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- ollajev-0.2.0/.editorconfig +15 -0
- ollajev-0.2.0/.github/ISSUE_TEMPLATE/bug_report.yml +40 -0
- ollajev-0.2.0/.github/ISSUE_TEMPLATE/config.yml +5 -0
- ollajev-0.2.0/.github/ISSUE_TEMPLATE/feature_request.yml +21 -0
- ollajev-0.2.0/.github/PULL_REQUEST_TEMPLATE.md +11 -0
- ollajev-0.2.0/.github/dependabot.yml +16 -0
- ollajev-0.2.0/.github/workflows/ci.yml +64 -0
- ollajev-0.2.0/.github/workflows/release.yml +56 -0
- ollajev-0.2.0/.gitignore +16 -0
- ollajev-0.2.0/.pre-commit-config.yaml +15 -0
- ollajev-0.2.0/CHANGELOG.md +67 -0
- ollajev-0.2.0/CODE_OF_CONDUCT.md +133 -0
- ollajev-0.2.0/CONTRIBUTING.md +85 -0
- ollajev-0.2.0/LICENSE +202 -0
- ollajev-0.2.0/NOTICE +13 -0
- ollajev-0.2.0/PKG-INFO +404 -0
- ollajev-0.2.0/PLAN.md +228 -0
- ollajev-0.2.0/README.md +362 -0
- ollajev-0.2.0/SECURITY.md +19 -0
- ollajev-0.2.0/TODO.md +68 -0
- ollajev-0.2.0/assets/logo.png +0 -0
- ollajev-0.2.0/assets/logo.svg +39 -0
- ollajev-0.2.0/assets/model-manager.png +0 -0
- ollajev-0.2.0/docs/index.html +850 -0
- ollajev-0.2.0/docs/logo.svg +39 -0
- ollajev-0.2.0/docs/tui-models.png +0 -0
- ollajev-0.2.0/docs/tui-search.png +0 -0
- ollajev-0.2.0/install.ps1 +43 -0
- ollajev-0.2.0/install.sh +98 -0
- ollajev-0.2.0/pyproject.toml +107 -0
- ollajev-0.2.0/src/ollajev/__init__.py +5 -0
- ollajev-0.2.0/src/ollajev/__main__.py +3 -0
- ollajev-0.2.0/src/ollajev/_vendor/__init__.py +0 -0
- ollajev-0.2.0/src/ollajev/_vendor/clef/LICENSE +202 -0
- ollajev-0.2.0/src/ollajev/_vendor/clef/VENDORED.md +3 -0
- ollajev-0.2.0/src/ollajev/_vendor/clef/__init__.py +0 -0
- ollajev-0.2.0/src/ollajev/_vendor/clef/joint_schema_model.py +576 -0
- ollajev-0.2.0/src/ollajev/_vendor/jevk5/LICENSE +202 -0
- ollajev-0.2.0/src/ollajev/_vendor/jevk5/VENDORED.md +3 -0
- ollajev-0.2.0/src/ollajev/_vendor/jevk5/__init__.py +0 -0
- ollajev-0.2.0/src/ollajev/_vendor/jevk5/prompt.py +173 -0
- ollajev-0.2.0/src/ollajev/_vendor/kev/LICENSE +202 -0
- ollajev-0.2.0/src/ollajev/_vendor/kev/VENDORED.md +5 -0
- ollajev-0.2.0/src/ollajev/_vendor/kev/__init__.py +0 -0
- ollajev-0.2.0/src/ollajev/_vendor/kev/api.py +165 -0
- ollajev-0.2.0/src/ollajev/_vendor/kev/checkpoint.py +356 -0
- ollajev-0.2.0/src/ollajev/_vendor/kev/device.py +30 -0
- ollajev-0.2.0/src/ollajev/_vendor/kev/model.py +508 -0
- ollajev-0.2.0/src/ollajev/adapters/__init__.py +128 -0
- ollajev-0.2.0/src/ollajev/adapters/base.py +47 -0
- ollajev-0.2.0/src/ollajev/adapters/clef.py +94 -0
- ollajev-0.2.0/src/ollajev/adapters/decider.py +67 -0
- ollajev-0.2.0/src/ollajev/adapters/decision1.py +39 -0
- ollajev-0.2.0/src/ollajev/adapters/intern.py +48 -0
- ollajev-0.2.0/src/ollajev/adapters/jevk5.py +245 -0
- ollajev-0.2.0/src/ollajev/adapters/julia.py +67 -0
- ollajev-0.2.0/src/ollajev/adapters/kev.py +135 -0
- ollajev-0.2.0/src/ollajev/adapters/laya.py +121 -0
- ollajev-0.2.0/src/ollajev/adapters/onejev.py +305 -0
- ollajev-0.2.0/src/ollajev/adapters/openjev.py +70 -0
- ollajev-0.2.0/src/ollajev/adapters/rlcd.py +132 -0
- ollajev-0.2.0/src/ollajev/adapters/von.py +77 -0
- ollajev-0.2.0/src/ollajev/catalog.py +52 -0
- ollajev-0.2.0/src/ollajev/client.py +58 -0
- ollajev-0.2.0/src/ollajev/config.py +231 -0
- ollajev-0.2.0/src/ollajev/library.py +66 -0
- ollajev-0.2.0/src/ollajev/manager.py +255 -0
- ollajev-0.2.0/src/ollajev/names.py +161 -0
- ollajev-0.2.0/src/ollajev/normalize.py +85 -0
- ollajev-0.2.0/src/ollajev/presets.py +136 -0
- ollajev-0.2.0/src/ollajev/py.typed +0 -0
- ollajev-0.2.0/src/ollajev/registry.py +67 -0
- ollajev-0.2.0/src/ollajev/server/__init__.py +1 -0
- ollajev-0.2.0/src/ollajev/server/admin.py +225 -0
- ollajev-0.2.0/src/ollajev/server/api.py +280 -0
- ollajev-0.2.0/src/ollajev/server/static/favicon.svg +39 -0
- ollajev-0.2.0/src/ollajev/server/static/main.js +689 -0
- ollajev-0.2.0/src/ollajev/server/static/playground.html +126 -0
- ollajev-0.2.0/src/ollajev/server/static/style.css +451 -0
- ollajev-0.2.0/src/ollajev/service.py +151 -0
- ollajev-0.2.0/src/ollajev/store.py +596 -0
- ollajev-0.2.0/src/ollajev/ui/__init__.py +1 -0
- ollajev-0.2.0/src/ollajev/ui/cli.py +425 -0
- ollajev-0.2.0/src/ollajev/ui/dialogs.py +457 -0
- ollajev-0.2.0/src/ollajev/ui/repl.py +140 -0
- ollajev-0.2.0/src/ollajev/ui/tui.py +1251 -0
- ollajev-0.2.0/tests/test_adapters.py +82 -0
- ollajev-0.2.0/tests/test_caches.py +123 -0
- ollajev-0.2.0/tests/test_clef.py +107 -0
- ollajev-0.2.0/tests/test_cli.py +130 -0
- ollajev-0.2.0/tests/test_client.py +40 -0
- ollajev-0.2.0/tests/test_contract.py +487 -0
- ollajev-0.2.0/tests/test_jevk5.py +122 -0
- ollajev-0.2.0/tests/test_layout.py +47 -0
- ollajev-0.2.0/tests/test_onejev.py +79 -0
- ollajev-0.2.0/tests/test_rlcd.py +67 -0
- ollajev-0.2.0/tests/test_security.py +262 -0
- ollajev-0.2.0/tests/test_tui.py +745 -0
- ollajev-0.2.0/tests/test_von.py +61 -0
- ollajev-0.2.0/uv.lock +1249 -0
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
name: Bug report
|
|
2
|
+
description: Something does not work as expected
|
|
3
|
+
labels: [bug]
|
|
4
|
+
body:
|
|
5
|
+
- type: markdown
|
|
6
|
+
attributes:
|
|
7
|
+
value: For security problems, do not file here. Use a private security advisory (see SECURITY.md).
|
|
8
|
+
- type: textarea
|
|
9
|
+
id: what
|
|
10
|
+
attributes:
|
|
11
|
+
label: What happened
|
|
12
|
+
description: What you did, what you expected, and what you got instead.
|
|
13
|
+
validations:
|
|
14
|
+
required: true
|
|
15
|
+
- type: textarea
|
|
16
|
+
id: repro
|
|
17
|
+
attributes:
|
|
18
|
+
label: Steps to reproduce
|
|
19
|
+
description: The exact commands or requests. Include the model repo (for example SupersonicLabs/Julia-1).
|
|
20
|
+
validations:
|
|
21
|
+
required: true
|
|
22
|
+
- type: input
|
|
23
|
+
id: version
|
|
24
|
+
attributes:
|
|
25
|
+
label: ollajev version
|
|
26
|
+
description: Output of `ollajev --version`
|
|
27
|
+
validations:
|
|
28
|
+
required: true
|
|
29
|
+
- type: input
|
|
30
|
+
id: platform
|
|
31
|
+
attributes:
|
|
32
|
+
label: OS, Python and hardware
|
|
33
|
+
placeholder: macOS 15, Python 3.12, Apple M3
|
|
34
|
+
validations:
|
|
35
|
+
required: true
|
|
36
|
+
- type: textarea
|
|
37
|
+
id: logs
|
|
38
|
+
attributes:
|
|
39
|
+
label: Logs or traceback
|
|
40
|
+
render: text
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
name: Feature request
|
|
2
|
+
description: Suggest an improvement or a new model family
|
|
3
|
+
labels: [enhancement]
|
|
4
|
+
body:
|
|
5
|
+
- type: textarea
|
|
6
|
+
id: problem
|
|
7
|
+
attributes:
|
|
8
|
+
label: Problem
|
|
9
|
+
description: What are you trying to do that ollajev does not support?
|
|
10
|
+
validations:
|
|
11
|
+
required: true
|
|
12
|
+
- type: textarea
|
|
13
|
+
id: proposal
|
|
14
|
+
attributes:
|
|
15
|
+
label: Proposed solution
|
|
16
|
+
validations:
|
|
17
|
+
required: true
|
|
18
|
+
- type: textarea
|
|
19
|
+
id: alternatives
|
|
20
|
+
attributes:
|
|
21
|
+
label: Alternatives considered
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
## What and why
|
|
2
|
+
|
|
3
|
+
<!-- What does this change, and why? Link the issue if there is one. -->
|
|
4
|
+
|
|
5
|
+
## Checklist
|
|
6
|
+
|
|
7
|
+
- [ ] `uv run ruff check src tests`, `uv run ruff format --check src tests`, `uv run pyright` and `uv run pytest` pass
|
|
8
|
+
- [ ] Tests added or updated
|
|
9
|
+
- [ ] `CHANGELOG.md` updated under `[Unreleased]` for user-visible changes
|
|
10
|
+
- [ ] Commits follow Conventional Commits
|
|
11
|
+
- [ ] I am contributing this under the Apache-2.0 license
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
version: 2
|
|
2
|
+
updates:
|
|
3
|
+
- package-ecosystem: github-actions
|
|
4
|
+
directory: /
|
|
5
|
+
schedule:
|
|
6
|
+
interval: weekly
|
|
7
|
+
groups:
|
|
8
|
+
actions:
|
|
9
|
+
patterns: ["*"]
|
|
10
|
+
- package-ecosystem: uv
|
|
11
|
+
directory: /
|
|
12
|
+
schedule:
|
|
13
|
+
interval: weekly
|
|
14
|
+
groups:
|
|
15
|
+
python-dependencies:
|
|
16
|
+
patterns: ["*"]
|
|
@@ -0,0 +1,64 @@
|
|
|
1
|
+
name: CI
|
|
2
|
+
|
|
3
|
+
on:
|
|
4
|
+
push:
|
|
5
|
+
branches: [main]
|
|
6
|
+
pull_request:
|
|
7
|
+
|
|
8
|
+
permissions:
|
|
9
|
+
contents: read
|
|
10
|
+
|
|
11
|
+
concurrency:
|
|
12
|
+
group: ci-${{ github.workflow }}-${{ github.ref }}
|
|
13
|
+
cancel-in-progress: ${{ github.event_name == 'pull_request' }}
|
|
14
|
+
|
|
15
|
+
jobs:
|
|
16
|
+
lint:
|
|
17
|
+
runs-on: ubuntu-latest
|
|
18
|
+
steps:
|
|
19
|
+
- uses: actions/checkout@fbc6f3992d24b796d5a048ff273f7fcc4a7b6c09 # v5
|
|
20
|
+
- uses: astral-sh/setup-uv@37802adc94f370d6bfd71619e3f0bf239e1f3b78 # v7
|
|
21
|
+
- run: uv sync --locked
|
|
22
|
+
- run: uv run ruff check src tests
|
|
23
|
+
- run: uv run ruff format --check src tests
|
|
24
|
+
- run: uv run pyright
|
|
25
|
+
|
|
26
|
+
test:
|
|
27
|
+
strategy:
|
|
28
|
+
fail-fast: false
|
|
29
|
+
matrix:
|
|
30
|
+
os: [ubuntu-latest, macos-latest, windows-latest]
|
|
31
|
+
runs-on: ${{ matrix.os }}
|
|
32
|
+
steps:
|
|
33
|
+
- uses: actions/checkout@fbc6f3992d24b796d5a048ff273f7fcc4a7b6c09 # v5
|
|
34
|
+
- uses: astral-sh/setup-uv@37802adc94f370d6bfd71619e3f0bf239e1f3b78 # v7
|
|
35
|
+
- run: uv sync --locked
|
|
36
|
+
- run: uv run pytest
|
|
37
|
+
|
|
38
|
+
supply-chain:
|
|
39
|
+
runs-on: ubuntu-latest
|
|
40
|
+
steps:
|
|
41
|
+
- uses: actions/checkout@fbc6f3992d24b796d5a048ff273f7fcc4a7b6c09 # v5
|
|
42
|
+
- uses: astral-sh/setup-uv@37802adc94f370d6bfd71619e3f0bf239e1f3b78 # v7
|
|
43
|
+
# Audits the locked runtime dependencies (no dev tools, not this project) against
|
|
44
|
+
# the PyPA advisory database. PYSEC-2026-2447 (diskcache 5.6.3) has no fixed version
|
|
45
|
+
# upstream, so it is ignored until one exists; remove the --ignore-vuln then.
|
|
46
|
+
- run: uv export --no-dev --locked --no-emit-project -o requirements-audit.txt
|
|
47
|
+
- run: uvx pip-audit --requirement requirements-audit.txt --disable-pip --ignore-vuln PYSEC-2026-2447
|
|
48
|
+
|
|
49
|
+
build:
|
|
50
|
+
runs-on: ubuntu-latest
|
|
51
|
+
steps:
|
|
52
|
+
- uses: actions/checkout@fbc6f3992d24b796d5a048ff273f7fcc4a7b6c09 # v5
|
|
53
|
+
- uses: astral-sh/setup-uv@37802adc94f370d6bfd71619e3f0bf239e1f3b78 # v7
|
|
54
|
+
- run: uv build
|
|
55
|
+
- run: uvx twine check dist/*
|
|
56
|
+
- name: Smoke test the built wheel in a clean venv
|
|
57
|
+
run: |
|
|
58
|
+
uv venv "$RUNNER_TEMP/smoke"
|
|
59
|
+
uv pip install --python "$RUNNER_TEMP/smoke/bin/python" dist/*.whl
|
|
60
|
+
"$RUNNER_TEMP/smoke/bin/ollajev" --version
|
|
61
|
+
- uses: actions/upload-artifact@330a01c490aca151604b8cf639adc76d48f6c5d4 # v5
|
|
62
|
+
with:
|
|
63
|
+
name: dist
|
|
64
|
+
path: dist/
|
|
@@ -0,0 +1,56 @@
|
|
|
1
|
+
name: Release
|
|
2
|
+
|
|
3
|
+
on:
|
|
4
|
+
push:
|
|
5
|
+
tags: ["v*"]
|
|
6
|
+
|
|
7
|
+
permissions:
|
|
8
|
+
contents: read
|
|
9
|
+
|
|
10
|
+
jobs:
|
|
11
|
+
build:
|
|
12
|
+
runs-on: ubuntu-latest
|
|
13
|
+
steps:
|
|
14
|
+
- uses: actions/checkout@fbc6f3992d24b796d5a048ff273f7fcc4a7b6c09 # v5
|
|
15
|
+
- uses: astral-sh/setup-uv@37802adc94f370d6bfd71619e3f0bf239e1f3b78 # v7
|
|
16
|
+
- name: Verify tag matches pyproject version
|
|
17
|
+
run: |
|
|
18
|
+
version=$(python3 -c "import tomllib; print(tomllib.load(open('pyproject.toml','rb'))['project']['version'])")
|
|
19
|
+
if [ "v$version" != "$GITHUB_REF_NAME" ]; then
|
|
20
|
+
echo "Tag $GITHUB_REF_NAME does not match pyproject version v$version" >&2
|
|
21
|
+
exit 1
|
|
22
|
+
fi
|
|
23
|
+
- run: uv build
|
|
24
|
+
- run: uvx twine check dist/*
|
|
25
|
+
- uses: actions/upload-artifact@330a01c490aca151604b8cf639adc76d48f6c5d4 # v5
|
|
26
|
+
with:
|
|
27
|
+
name: dist
|
|
28
|
+
path: dist/
|
|
29
|
+
|
|
30
|
+
publish:
|
|
31
|
+
needs: build
|
|
32
|
+
runs-on: ubuntu-latest
|
|
33
|
+
environment: pypi
|
|
34
|
+
permissions:
|
|
35
|
+
id-token: write
|
|
36
|
+
steps:
|
|
37
|
+
- uses: actions/download-artifact@634f93cb2916e3fdff6788551b99b062d0335ce0 # v5
|
|
38
|
+
with:
|
|
39
|
+
name: dist
|
|
40
|
+
path: dist/
|
|
41
|
+
- uses: pypa/gh-action-pypi-publish@dc37677b2e1c63e2034f94d8a5b11f265b73ba33 # v1.14.2
|
|
42
|
+
|
|
43
|
+
github-release:
|
|
44
|
+
needs: publish
|
|
45
|
+
runs-on: ubuntu-latest
|
|
46
|
+
permissions:
|
|
47
|
+
contents: write
|
|
48
|
+
steps:
|
|
49
|
+
- uses: actions/download-artifact@634f93cb2916e3fdff6788551b99b062d0335ce0 # v5
|
|
50
|
+
with:
|
|
51
|
+
name: dist
|
|
52
|
+
path: dist/
|
|
53
|
+
- name: Create GitHub release
|
|
54
|
+
env:
|
|
55
|
+
GH_TOKEN: ${{ github.token }}
|
|
56
|
+
run: gh release create "$GITHUB_REF_NAME" dist/* --repo "$GITHUB_REPOSITORY" --generate-notes --verify-tag
|
ollajev-0.2.0/.gitignore
ADDED
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
repos:
|
|
2
|
+
- repo: https://github.com/pre-commit/pre-commit-hooks
|
|
3
|
+
rev: v6.0.0
|
|
4
|
+
hooks:
|
|
5
|
+
- id: end-of-file-fixer
|
|
6
|
+
- id: trailing-whitespace
|
|
7
|
+
- id: check-yaml
|
|
8
|
+
- id: check-toml
|
|
9
|
+
- id: check-added-large-files
|
|
10
|
+
- repo: https://github.com/astral-sh/ruff-pre-commit
|
|
11
|
+
rev: v0.16.9
|
|
12
|
+
hooks:
|
|
13
|
+
- id: ruff-check
|
|
14
|
+
args: [--fix]
|
|
15
|
+
- id: ruff-format
|
|
@@ -0,0 +1,67 @@
|
|
|
1
|
+
# Changelog
|
|
2
|
+
|
|
3
|
+
All notable changes to this project are documented here. The format follows
|
|
4
|
+
[Keep a Changelog](https://keepachangelog.com/en/1.1.0/) and the project uses
|
|
5
|
+
[Semantic Versioning](https://semver.org/).
|
|
6
|
+
|
|
7
|
+
## [Unreleased]
|
|
8
|
+
|
|
9
|
+
## [0.2.0] - 2026-10-05
|
|
10
|
+
|
|
11
|
+
First release on PyPI: `uv tool install ollajev`.
|
|
12
|
+
|
|
13
|
+
### Security
|
|
14
|
+
|
|
15
|
+
- `POST /api/pull` no longer accepts `trust`; trusting a repo's Python code is CLI-only.
|
|
16
|
+
- `OLLAJEV_API_KEY` requires a bearer token on every API route. Listening on a non-loopback
|
|
17
|
+
address without it is refused. On loopback, only `localhost`, `127.0.0.1` and `[::1]` are
|
|
18
|
+
accepted as Host (DNS-rebinding guard).
|
|
19
|
+
- Model names reject `.`/`..` segments and foreign URL hosts.
|
|
20
|
+
- Requests over `OLLAJEV_MAX_BODY_BYTES` (8 MiB) get 413. The demo page sends a Content-Security-Policy.
|
|
21
|
+
|
|
22
|
+
### Changed
|
|
23
|
+
|
|
24
|
+
- The demo page is now the playground, at `/playground`; `/demo` redirects there. The model manager's
|
|
25
|
+
button and the server banner say Playground.
|
|
26
|
+
- `ollajev setup` (alias `tui`) is now a model manager: download, switch the default, unload, delete,
|
|
27
|
+
alias, inspect and serve from one screen. A Selected card shows the model at the cursor with buttons for
|
|
28
|
+
what applies to it, a Server card shows the running server with Playground, Logs, Restart and Stop, and the
|
|
29
|
+
status row lists the keys. Every button shows its key as `[key] label`. Ask is hidden for now.
|
|
30
|
+
- The model manager uses the terminal's own colours and has no theme picker.
|
|
31
|
+
- Keys: `a` adds a model, `f` filters, `c` gives a short name, `s` serves the selected model, `R` restarts
|
|
32
|
+
and `S` stops the server, `l` follows the server logs in a new terminal tab.
|
|
33
|
+
- The model manager starts faster: listing downloads no longer imports PyTorch.
|
|
34
|
+
- The playground opens on the model the server has loaded.
|
|
35
|
+
|
|
36
|
+
- Config and logs now live in `~/.ollajev` (override with `OLLAJEV_HOME`). A config in the old OS
|
|
37
|
+
folder is read once and moved on the next save.
|
|
38
|
+
- Dependencies use compatible ranges in `pyproject.toml`; `uv.lock` keeps exact versions.
|
|
39
|
+
- Installers pin to a release tag.
|
|
40
|
+
|
|
41
|
+
### Fixed
|
|
42
|
+
|
|
43
|
+
- `install.sh` checks for a C and C++ compiler on Linux, which llama.cpp needs, and says how to install one.
|
|
44
|
+
- A failing `systemctl` or `launchctl` call in `ollajev service` ends with its message, not a traceback.
|
|
45
|
+
- Config writes are locked and atomic; a corrupt `config.json` is moved to `config.json.bad`.
|
|
46
|
+
- A request can no longer run on a model the reaper just unloaded; eviction reads the slot table
|
|
47
|
+
under its lock.
|
|
48
|
+
- Two pulls of the same repo cannot run at once; unexpected pull errors are logged, not sent to the client.
|
|
49
|
+
- Repo-code imports are serialised.
|
|
50
|
+
- Removing one quant no longer deletes a blob another revision still uses.
|
|
51
|
+
- A failed download no longer leaves a pin.
|
|
52
|
+
- A bad `OLLAJEV_HOST`, `OLLAJEV_KEEP_ALIVE` or `OLLAJEV_MAX_LOADED_MODELS` gives a one-line error naming the variable.
|
|
53
|
+
|
|
54
|
+
### Added
|
|
55
|
+
|
|
56
|
+
- Jev / System One API (`GET /v1/models`, `POST /v1/systemone`), drop-in for `typesafe-sdk`.
|
|
57
|
+
- Adapters for seven model families: decider (PyTorch and llama.cpp GGUF), laya, Julia,
|
|
58
|
+
open-jev, kev, Intern-Decision and Decision-1.0. Sixteen curated models under 4 GB.
|
|
59
|
+
- Ollama-style model names (`repo`, `repo:quant`, `repo:file.gguf`, `hf.co/` prefix), pinned to the
|
|
60
|
+
commit of first download.
|
|
61
|
+
- Model manager: load on request, `keep_alive` unload, least-recently-used eviction.
|
|
62
|
+
- Trust prompt per repo and commit for families that run code from the model repo.
|
|
63
|
+
- Ollama-style management API (`/api/tags`, `ps`, `pull`, `show`, `delete`, `copy`, `stop`) and
|
|
64
|
+
CLI (`serve`, `setup`, `run`, `pull`, `list`, `ps`, `show`, `rm`, `stop`, `cp`, `service`).
|
|
65
|
+
- Textual setup screen on first run; interactive `run`.
|
|
66
|
+
- Demo page with a model picker and per-model limits.
|
|
67
|
+
- `install.sh` / `install.ps1`, and a background service (launchd, systemd user unit).
|
|
@@ -0,0 +1,133 @@
|
|
|
1
|
+
# Contributor Covenant Code of Conduct
|
|
2
|
+
|
|
3
|
+
## Our Pledge
|
|
4
|
+
|
|
5
|
+
We as members, contributors, and leaders pledge to make participation in our
|
|
6
|
+
community a harassment-free experience for everyone, regardless of age, body
|
|
7
|
+
size, visible or invisible disability, ethnicity, sex characteristics, gender
|
|
8
|
+
identity and expression, level of experience, education, socio-economic status,
|
|
9
|
+
nationality, personal appearance, race, caste, color, religion, or sexual
|
|
10
|
+
identity and orientation.
|
|
11
|
+
|
|
12
|
+
We pledge to act and interact in ways that contribute to an open, welcoming,
|
|
13
|
+
diverse, inclusive, and healthy community.
|
|
14
|
+
|
|
15
|
+
## Our Standards
|
|
16
|
+
|
|
17
|
+
Examples of behavior that contributes to a positive environment for our
|
|
18
|
+
community include:
|
|
19
|
+
|
|
20
|
+
* Demonstrating empathy and kindness toward other people
|
|
21
|
+
* Being respectful of differing opinions, viewpoints, and experiences
|
|
22
|
+
* Giving and gracefully accepting constructive feedback
|
|
23
|
+
* Accepting responsibility and apologizing to those affected by our mistakes,
|
|
24
|
+
and learning from the experience
|
|
25
|
+
* Focusing on what is best not just for us as individuals, but for the overall
|
|
26
|
+
community
|
|
27
|
+
|
|
28
|
+
Examples of unacceptable behavior include:
|
|
29
|
+
|
|
30
|
+
* The use of sexualized language or imagery, and sexual attention or advances of
|
|
31
|
+
any kind
|
|
32
|
+
* Trolling, insulting or derogatory comments, and personal or political attacks
|
|
33
|
+
* Public or private harassment
|
|
34
|
+
* Publishing others' private information, such as a physical or email address,
|
|
35
|
+
without their explicit permission
|
|
36
|
+
* Other conduct which could reasonably be considered inappropriate in a
|
|
37
|
+
professional setting
|
|
38
|
+
|
|
39
|
+
## Enforcement Responsibilities
|
|
40
|
+
|
|
41
|
+
Community leaders are responsible for clarifying and enforcing our standards of
|
|
42
|
+
acceptable behavior and will take appropriate and fair corrective action in
|
|
43
|
+
response to any behavior that they deem inappropriate, threatening, offensive,
|
|
44
|
+
or harmful.
|
|
45
|
+
|
|
46
|
+
Community leaders have the right and responsibility to remove, edit, or reject
|
|
47
|
+
comments, commits, code, wiki edits, issues, and other contributions that are
|
|
48
|
+
not aligned to this Code of Conduct, and will communicate reasons for moderation
|
|
49
|
+
decisions when appropriate.
|
|
50
|
+
|
|
51
|
+
## Scope
|
|
52
|
+
|
|
53
|
+
This Code of Conduct applies within all community spaces, and also applies when
|
|
54
|
+
an individual is officially representing the community in public spaces.
|
|
55
|
+
Examples of representing our community include using an official e-mail address,
|
|
56
|
+
posting via an official social media account, or acting as an appointed
|
|
57
|
+
representative at an online or offline event.
|
|
58
|
+
|
|
59
|
+
## Enforcement
|
|
60
|
+
|
|
61
|
+
Instances of abusive, harassing, or otherwise unacceptable behavior may be
|
|
62
|
+
reported to the community leaders responsible for enforcement by opening a
|
|
63
|
+
[private security advisory](https://github.com/nvkudva/ollajev/security/advisories/new)
|
|
64
|
+
on the repository, or by contacting the maintainer through the repository. All
|
|
65
|
+
complaints will be reviewed and investigated promptly and fairly.
|
|
66
|
+
|
|
67
|
+
All community leaders are obligated to respect the privacy and security of the
|
|
68
|
+
reporter of any incident.
|
|
69
|
+
|
|
70
|
+
## Enforcement Guidelines
|
|
71
|
+
|
|
72
|
+
Community leaders will follow these Community Impact Guidelines in determining
|
|
73
|
+
the consequences for any action they deem in violation of this Code of Conduct:
|
|
74
|
+
|
|
75
|
+
### 1. Correction
|
|
76
|
+
|
|
77
|
+
**Community Impact**: Use of inappropriate language or other behavior deemed
|
|
78
|
+
unprofessional or unwelcome in the community.
|
|
79
|
+
|
|
80
|
+
**Consequence**: A private, written warning from community leaders, providing
|
|
81
|
+
clarity around the nature of the violation and an explanation of why the
|
|
82
|
+
behavior was inappropriate. A public apology may be requested.
|
|
83
|
+
|
|
84
|
+
### 2. Warning
|
|
85
|
+
|
|
86
|
+
**Community Impact**: A violation through a single incident or series of
|
|
87
|
+
actions.
|
|
88
|
+
|
|
89
|
+
**Consequence**: A warning with consequences for continued behavior. No
|
|
90
|
+
interaction with the people involved, including unsolicited interaction with
|
|
91
|
+
those enforcing the Code of Conduct, for a specified period of time. This
|
|
92
|
+
includes avoiding interactions in community spaces as well as external channels
|
|
93
|
+
like social media. Violating these terms may lead to a temporary or permanent
|
|
94
|
+
ban.
|
|
95
|
+
|
|
96
|
+
### 3. Temporary Ban
|
|
97
|
+
|
|
98
|
+
**Community Impact**: A serious violation of community standards, including
|
|
99
|
+
sustained inappropriate behavior.
|
|
100
|
+
|
|
101
|
+
**Consequence**: A temporary ban from any sort of interaction or public
|
|
102
|
+
communication with the community for a specified period of time. No public or
|
|
103
|
+
private interaction with the people involved, including unsolicited interaction
|
|
104
|
+
with those enforcing the Code of Conduct, is allowed during this period.
|
|
105
|
+
Violating these terms may lead to a permanent ban.
|
|
106
|
+
|
|
107
|
+
### 4. Permanent Ban
|
|
108
|
+
|
|
109
|
+
**Community Impact**: Demonstrating a pattern of violation of community
|
|
110
|
+
standards, including sustained inappropriate behavior, harassment of an
|
|
111
|
+
individual, or aggression toward or disparagement of classes of individuals.
|
|
112
|
+
|
|
113
|
+
**Consequence**: A permanent ban from any sort of public interaction within the
|
|
114
|
+
community.
|
|
115
|
+
|
|
116
|
+
## Attribution
|
|
117
|
+
|
|
118
|
+
This Code of Conduct is adapted from the [Contributor Covenant][homepage],
|
|
119
|
+
version 2.1, available at
|
|
120
|
+
[https://www.contributor-covenant.org/version/2/1/code_of_conduct.html][v2.1].
|
|
121
|
+
|
|
122
|
+
Community Impact Guidelines were inspired by
|
|
123
|
+
[Mozilla's code of conduct enforcement ladder][Mozilla CoC].
|
|
124
|
+
|
|
125
|
+
For answers to common questions about this code of conduct, see the FAQ at
|
|
126
|
+
[https://www.contributor-covenant.org/faq][FAQ]. Translations are available at
|
|
127
|
+
[https://www.contributor-covenant.org/translations][translations].
|
|
128
|
+
|
|
129
|
+
[homepage]: https://www.contributor-covenant.org
|
|
130
|
+
[v2.1]: https://www.contributor-covenant.org/version/2/1/code_of_conduct.html
|
|
131
|
+
[Mozilla CoC]: https://github.com/mozilla/diversity
|
|
132
|
+
[FAQ]: https://www.contributor-covenant.org/faq
|
|
133
|
+
[translations]: https://www.contributor-covenant.org/translations
|
|
@@ -0,0 +1,85 @@
|
|
|
1
|
+
# Contributing
|
|
2
|
+
|
|
3
|
+
## Setup
|
|
4
|
+
|
|
5
|
+
```sh
|
|
6
|
+
git clone https://github.com/nvkudva/ollajev.git
|
|
7
|
+
cd ollajev
|
|
8
|
+
uv sync # Python 3.12 environment with the dev tools
|
|
9
|
+
uv run ollajev --help
|
|
10
|
+
```
|
|
11
|
+
|
|
12
|
+
## Checks
|
|
13
|
+
|
|
14
|
+
Run these before opening a pull request. CI runs the same ones.
|
|
15
|
+
|
|
16
|
+
```sh
|
|
17
|
+
uv run ruff check src tests
|
|
18
|
+
uv run ruff format --check src tests
|
|
19
|
+
uv run pyright
|
|
20
|
+
uv run pytest
|
|
21
|
+
```
|
|
22
|
+
|
|
23
|
+
`uv run pre-commit install` runs ruff on every commit.
|
|
24
|
+
|
|
25
|
+
The tests load no model weights. To check a change against a real model, run the server and send
|
|
26
|
+
it a request:
|
|
27
|
+
|
|
28
|
+
```sh
|
|
29
|
+
OLLAJEV_HOME=/tmp/ollajev-dev uv run ollajev serve SupersonicLabs/Julia-1 --port 8765
|
|
30
|
+
```
|
|
31
|
+
|
|
32
|
+
## Layout
|
|
33
|
+
|
|
34
|
+
| Path | What it holds |
|
|
35
|
+
|---|---|
|
|
36
|
+
| `src/ollajev/ui/` | front ends: `cli.py` command line, `repl.py` for `ollajev run`, `tui.py` model manager |
|
|
37
|
+
| `src/ollajev/server/` | HTTP routes: `api.py` Jev API, `admin.py` management API, `static/` playground page |
|
|
38
|
+
| `src/ollajev/client.py` | talking to a running server, for the front ends |
|
|
39
|
+
| `src/ollajev/manager.py` | loading, unloading and running models |
|
|
40
|
+
| `src/ollajev/store.py`, `names.py` | model names, pinned downloads, trust |
|
|
41
|
+
| `src/ollajev/adapters/` | one module per model family |
|
|
42
|
+
| `src/ollajev/normalize.py` | answers in the TypeSafe shape |
|
|
43
|
+
| `src/ollajev/_vendor/kev/` | kev's loader, vendored; do not edit except as noted in `VENDORED.md` |
|
|
44
|
+
|
|
45
|
+
Everything else in `src/ollajev/` is the core. The core never imports `server/` or `ui/`, and `server/`
|
|
46
|
+
never imports `ui/`; `tests/test_layout.py` checks this.
|
|
47
|
+
|
|
48
|
+
## Adding a model family
|
|
49
|
+
|
|
50
|
+
Add a module under `src/ollajev/adapters/` with a `FAMILY` object that implements the `Family`
|
|
51
|
+
protocol in `adapters/__init__.py` (`matches`, `allow_patterns`, `limits`, `load`), and register it
|
|
52
|
+
in `families()`. Set `runs_repo_code = True` if it imports Python from the model repo. Run the new
|
|
53
|
+
model end to end through `/v1/systemone` before adding it to `catalog.py`.
|
|
54
|
+
|
|
55
|
+
## Running tests
|
|
56
|
+
|
|
57
|
+
```sh
|
|
58
|
+
uv run pytest
|
|
59
|
+
```
|
|
60
|
+
|
|
61
|
+
## Lint and type check
|
|
62
|
+
|
|
63
|
+
```sh
|
|
64
|
+
uv run ruff check
|
|
65
|
+
uv run pyright
|
|
66
|
+
```
|
|
67
|
+
|
|
68
|
+
## Releasing
|
|
69
|
+
|
|
70
|
+
1. Bump `version` in `pyproject.toml`.
|
|
71
|
+
2. Move the `[Unreleased]` entries in `CHANGELOG.md` under the new version.
|
|
72
|
+
3. Commit, then tag `vX.Y.Z` and push the tag.
|
|
73
|
+
|
|
74
|
+
`.github/workflows/release.yml` checks the tag matches `pyproject.toml`, builds, publishes to PyPI
|
|
75
|
+
with trusted publishing, and creates the GitHub release.
|
|
76
|
+
|
|
77
|
+
## Commits
|
|
78
|
+
|
|
79
|
+
Use [Conventional Commits](https://www.conventionalcommits.org/) (`feat:`, `fix:`, `docs:` …) and
|
|
80
|
+
add a line to `CHANGELOG.md` under `[Unreleased]` for user-visible changes.
|
|
81
|
+
|
|
82
|
+
## License
|
|
83
|
+
|
|
84
|
+
Contributions are made under the Apache-2.0 license, the same as the project. There is no CLA.
|
|
85
|
+
Add a `Signed-off-by` line (`git commit -s`) if you like; it is not required.
|