machina-cli 0.2.26__tar.gz → 0.3.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.
- {machina_cli-0.2.26 → machina_cli-0.3.0}/CHANGELOG.md +25 -0
- machina_cli-0.3.0/CLAUDE.md +19 -0
- {machina_cli-0.2.26 → machina_cli-0.3.0}/PKG-INFO +1 -1
- machina_cli-0.3.0/docs/agentic-harness-loop.md +771 -0
- machina_cli-0.3.0/docs/credentials.md +64 -0
- machina_cli-0.3.0/docs/loop-tools-connector.py +95 -0
- machina_cli-0.3.0/docs-site/.gitignore +4 -0
- machina_cli-0.3.0/docs-site/.vitepress/config.mts +97 -0
- machina_cli-0.3.0/docs-site/.vitepress/theme/custom.css +22 -0
- machina_cli-0.3.0/docs-site/.vitepress/theme/index.ts +4 -0
- machina_cli-0.3.0/docs-site/README.md +42 -0
- machina_cli-0.3.0/docs-site/commands/agent.md +36 -0
- machina_cli-0.3.0/docs-site/commands/config.md +24 -0
- machina_cli-0.3.0/docs-site/commands/connector.md +20 -0
- machina_cli-0.3.0/docs-site/commands/credentials.md +28 -0
- machina_cli-0.3.0/docs-site/commands/deploy.md +23 -0
- machina_cli-0.3.0/docs-site/commands/document.md +19 -0
- machina_cli-0.3.0/docs-site/commands/execution.md +24 -0
- machina_cli-0.3.0/docs-site/commands/factory.md +113 -0
- machina_cli-0.3.0/docs-site/commands/login.md +32 -0
- machina_cli-0.3.0/docs-site/commands/mapping.md +18 -0
- machina_cli-0.3.0/docs-site/commands/org.md +24 -0
- machina_cli-0.3.0/docs-site/commands/project.md +27 -0
- machina_cli-0.3.0/docs-site/commands/prompt.md +18 -0
- machina_cli-0.3.0/docs-site/commands/skills.md +29 -0
- machina_cli-0.3.0/docs-site/commands/sports.md +44 -0
- machina_cli-0.3.0/docs-site/commands/template.md +39 -0
- machina_cli-0.3.0/docs-site/commands/update.md +21 -0
- machina_cli-0.3.0/docs-site/commands/workflow.md +35 -0
- machina_cli-0.3.0/docs-site/guide/authentication.md +52 -0
- machina_cli-0.3.0/docs-site/guide/configuration.md +55 -0
- machina_cli-0.3.0/docs-site/guide/installation.md +62 -0
- machina_cli-0.3.0/docs-site/guide/quickstart.md +47 -0
- machina_cli-0.3.0/docs-site/guide/repl.md +44 -0
- machina_cli-0.3.0/docs-site/guide/running.md +60 -0
- machina_cli-0.3.0/docs-site/index.md +66 -0
- machina_cli-0.3.0/docs-site/package-lock.json +2513 -0
- machina_cli-0.3.0/docs-site/package.json +14 -0
- machina_cli-0.3.0/docs-site/public/favicon.ico +0 -0
- machina_cli-0.3.0/docs-site/public/machina-logo-dark.png +0 -0
- machina_cli-0.3.0/docs-site/public/machina-logo-light.png +0 -0
- machina_cli-0.3.0/docs-site/vercel.json +7 -0
- {machina_cli-0.2.26 → machina_cli-0.3.0}/pyproject.toml +1 -1
- {machina_cli-0.2.26 → machina_cli-0.3.0}/src/machina_cli/__init__.py +1 -1
- {machina_cli-0.2.26 → machina_cli-0.3.0}/src/machina_cli/commands/auth.py +27 -3
- machina_cli-0.3.0/src/machina_cli/commands/config_cmd.py +78 -0
- machina_cli-0.3.0/src/machina_cli/commands/connect.py +185 -0
- {machina_cli-0.2.26 → machina_cli-0.3.0}/src/machina_cli/commands/credentials.py +39 -8
- {machina_cli-0.2.26 → machina_cli-0.3.0}/src/machina_cli/commands/deploy.py +17 -1
- machina_cli-0.3.0/src/machina_cli/commands/loop.py +160 -0
- machina_cli-0.3.0/src/machina_cli/commands/mcp.py +126 -0
- machina_cli-0.3.0/src/machina_cli/loop_client.py +87 -0
- {machina_cli-0.2.26 → machina_cli-0.3.0}/src/machina_cli/main.py +20 -1
- {machina_cli-0.2.26 → machina_cli-0.3.0}/src/machina_cli/repl.py +122 -45
- machina_cli-0.3.0/tests/test_cli_output.py +219 -0
- machina_cli-0.3.0/tests/test_connect.py +317 -0
- machina_cli-0.3.0/tests/test_mcp_url.py +180 -0
- machina_cli-0.2.26/docs/factory.md +0 -167
- machina_cli-0.2.26/src/machina_cli/commands/config_cmd.py +0 -48
- {machina_cli-0.2.26 → machina_cli-0.3.0}/.github/workflows/ci.yml +0 -0
- {machina_cli-0.2.26 → machina_cli-0.3.0}/.github/workflows/release.yml +0 -0
- {machina_cli-0.2.26 → machina_cli-0.3.0}/.gitignore +0 -0
- {machina_cli-0.2.26 → machina_cli-0.3.0}/README.md +0 -0
- {machina_cli-0.2.26 → machina_cli-0.3.0}/install.ps1 +0 -0
- {machina_cli-0.2.26 → machina_cli-0.3.0}/install.sh +0 -0
- {machina_cli-0.2.26 → machina_cli-0.3.0}/src/machina_cli/browser_auth.py +0 -0
- {machina_cli-0.2.26 → machina_cli-0.3.0}/src/machina_cli/client.py +0 -0
- {machina_cli-0.2.26 → machina_cli-0.3.0}/src/machina_cli/commands/__init__.py +0 -0
- {machina_cli-0.2.26 → machina_cli-0.3.0}/src/machina_cli/commands/agent.py +0 -0
- {machina_cli-0.2.26 → machina_cli-0.3.0}/src/machina_cli/commands/connector.py +0 -0
- {machina_cli-0.2.26 → machina_cli-0.3.0}/src/machina_cli/commands/document.py +0 -0
- {machina_cli-0.2.26 → machina_cli-0.3.0}/src/machina_cli/commands/execution.py +0 -0
- {machina_cli-0.2.26 → machina_cli-0.3.0}/src/machina_cli/commands/factory.py +0 -0
- {machina_cli-0.2.26 → machina_cli-0.3.0}/src/machina_cli/commands/mapping.py +0 -0
- {machina_cli-0.2.26 → machina_cli-0.3.0}/src/machina_cli/commands/org.py +0 -0
- {machina_cli-0.2.26 → machina_cli-0.3.0}/src/machina_cli/commands/project.py +0 -0
- {machina_cli-0.2.26 → machina_cli-0.3.0}/src/machina_cli/commands/prompt.py +0 -0
- {machina_cli-0.2.26 → machina_cli-0.3.0}/src/machina_cli/commands/skills.py +0 -0
- {machina_cli-0.2.26 → machina_cli-0.3.0}/src/machina_cli/commands/sports.py +0 -0
- {machina_cli-0.2.26 → machina_cli-0.3.0}/src/machina_cli/commands/template.py +0 -0
- {machina_cli-0.2.26 → machina_cli-0.3.0}/src/machina_cli/commands/workflow.py +0 -0
- {machina_cli-0.2.26 → machina_cli-0.3.0}/src/machina_cli/config.py +0 -0
- {machina_cli-0.2.26 → machina_cli-0.3.0}/src/machina_cli/factory_client.py +0 -0
- {machina_cli-0.2.26 → machina_cli-0.3.0}/src/machina_cli/models/__init__.py +0 -0
- {machina_cli-0.2.26 → machina_cli-0.3.0}/src/machina_cli/project_client.py +0 -0
- {machina_cli-0.2.26 → machina_cli-0.3.0}/src/machina_cli/updater.py +0 -0
- {machina_cli-0.2.26 → machina_cli-0.3.0}/tests/__init__.py +0 -0
- {machina_cli-0.2.26 → machina_cli-0.3.0}/tests/test_sports_integration.py +0 -0
|
@@ -2,6 +2,31 @@
|
|
|
2
2
|
|
|
3
3
|
All notable changes to machina-cli are documented here.
|
|
4
4
|
|
|
5
|
+
## [0.3.0] - 2026-06-26
|
|
6
|
+
|
|
7
|
+
### Added
|
|
8
|
+
- **`machina loop …`**: drive a durable agentic turn loop (harness) that runs server-side on Studio primitives, with the CLI as a thin driver/observer (same pattern as `machina factory`). Commands: `run`, `watch`, `say`, `stop`, `sessions`.
|
|
9
|
+
- **Durable**: the loop is a scheduled agent + `harness_session` documents; each turn is persisted before advancing, and the beat resumes a session left `active` (survives crash / async tool / awaiting input). A turn ends at `idle` (awaiting the next `say`).
|
|
10
|
+
- **Multi-turn**: `say` injects a follow-up; prior conversation is fed back to the model. `watch` is turn-aware and streams new turns (incl. `→ tool` / `← result` steps).
|
|
11
|
+
- Server-side resources (prompt/workflow/agent) live in the project's Studio; the CLI reuses the existing project session — no new credential.
|
|
12
|
+
- Architecture + chapter-by-chapter build (caps 1–7) and verified platform contracts: `docs/agentic-harness-loop.md`. Dynamic multi-tool dispatcher reference: `docs/loop-tools-connector.py`.
|
|
13
|
+
|
|
14
|
+
## [0.2.27] - 2026-06-25
|
|
15
|
+
|
|
16
|
+
### Added
|
|
17
|
+
- **`machina connect [project]`**: one-command MCP connection bundle for external agents (e.g. sportsclaw) — emits `{name, url, transport, auth_header, token, masked, durable}` so an agent can register a Machina MCP server with no hand-pasted URL. Token is masked by default; `--reveal` emits it (in `--json`, `token` is `null` unless `--reveal`, so a script can't mistake a redacted string for a credential). `--mint` reuses or creates a dedicated `sportsclaw-<project>` project API key for a durable connection (refuses to mint a duplicate); `--org` supplies the organization inline; `--probe` checks reachability with the credential actually emitted.
|
|
18
|
+
- **`machina mcp url [project]`**: resolve a project's MCP endpoint (`{client-api}/mcp/sse`, SSE transport, `X-Api-Token`/`X-Session-Token` auth) from the project-token JWT `api` claim. `--probe` verifies the SSE endpoint is reachable and fails loud on a wrong derivation; `--json` for machine output. Verified against machina-core-api + machina-client-api.
|
|
19
|
+
- **`--json` on identity/config/deploy commands**: `whoami`, `config get`, `config list`, `deploy status`, and `credentials list` now emit machine-readable JSON. Error paths use a consistent `{"error": ...}` envelope with a non-zero exit.
|
|
20
|
+
- **`docs/credentials.md`**: documents `~/.machina/config.json` + `credentials.json` as a stable integration contract (fields, mode `600`, env overrides, `resolve_auth_token` precedence) so other tools can read it for unified, one-time login.
|
|
21
|
+
- REPL: `mcp` and `connect` added to the command list, tab-completion, and help.
|
|
22
|
+
|
|
23
|
+
### Changed
|
|
24
|
+
- **Secret redaction**: `config list` masks secret-looking keys; `config get <secret>` masks by default with `--reveal` to opt in. `credentials list` key masking is fail-safe — a short key is never echoed verbatim, and the JSON `masked` flag is honest.
|
|
25
|
+
|
|
26
|
+
### Fixed
|
|
27
|
+
- `config get --json` now signals a missing key (`{"error": "key not found"}` + exit 1) instead of `value: null` with exit 0.
|
|
28
|
+
- `deploy status` and `credentials list` in `--json` mode emit a JSON error envelope on API failure instead of no output.
|
|
29
|
+
|
|
5
30
|
## [0.2.26] - 2026-05-31
|
|
6
31
|
|
|
7
32
|
### Changed
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
# CLAUDE.md - machina-cli Guidelines
|
|
2
|
+
|
|
3
|
+
## Tech Stack
|
|
4
|
+
- Language: Python 3.10+
|
|
5
|
+
- Package Manager: uv (for local development dependencies)
|
|
6
|
+
- Build System: hatch / hatchling
|
|
7
|
+
- Shell Scripts: install.sh, install.ps1 (must be kept functional and lightweight)
|
|
8
|
+
|
|
9
|
+
## Commands
|
|
10
|
+
- Install for development: `uv pip install -e .`
|
|
11
|
+
- Build package: `hatch build`
|
|
12
|
+
- Run CLI locally: `python -m machina_cli` or `machina` (if installed in dev mode)
|
|
13
|
+
- Format Code: `ruff format .`
|
|
14
|
+
- Lint Code: `ruff check .`
|
|
15
|
+
|
|
16
|
+
## Code Conventions
|
|
17
|
+
- No Heavy Dependencies: The CLI must remain a thin, fast shell. Avoid adding thick libraries (like pandas, heavy SDKs) unless strictly required.
|
|
18
|
+
- Standard Output: Always output structured JSON when `--json` flag is provided. Default console output must be clean, ANSI-colored, and user-friendly.
|
|
19
|
+
- Files: kebab-case or snake_case as appropriate for Python.
|