Metadata-Version: 2.1
Name: company-os
Version: 1.5.4
Summary: Host-agnostic multi-agent company framework
Author: Mohit Meena
License: MIT
Project-URL: Homepage, https://github.com/mohitmeena144/company-os
Project-URL: Repository, https://github.com/mohitmeena144/company-os
Project-URL: Documentation, https://github.com/mohitmeena144/company-os#readme
Keywords: agents,multi-agent,cursor,workflow
Classifier: Intended Audience :: Developers
Classifier: License :: OSI Approved :: MIT License
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.10
Classifier: Programming Language :: Python :: 3.11
Classifier: Programming Language :: Python :: 3.12
Requires-Python: >=3.10
Description-Content-Type: text/markdown
License-File: LICENSE
Requires-Dist: pyyaml>=6
Requires-Dist: requests>=2.31
Provides-Extra: dev
Requires-Dist: pytest>=8; extra == "dev"
Requires-Dist: build<1.3,>=1.2; extra == "dev"
Requires-Dist: twine>=6.1; extra == "dev"
Provides-Extra: binary
Requires-Dist: shiv>=1.0.8; extra == "binary"
Provides-Extra: google
Requires-Dist: google-auth>=2.29.0; extra == "google"
Requires-Dist: google-auth-oauthlib>=1.2.0; extra == "google"
Requires-Dist: google-api-python-client>=2.130.0; extra == "google"
Provides-Extra: mongodb
Requires-Dist: pymongo>=4.6; extra == "mongodb"

# company-os

Autonomous business platform — a host-agnostic multi-agent framework organized around
**business functions** (Management, Marketing, Sales, Operations, Accounts, Legal, HR,
Engineering), each with a manager agent, a team, and a numbers-driven functional goal.
Install into any repo; it compiles a neutral `.company-os/` source into the host(s) you
enable (Cursor today; Claude/Codex later).

Extracted from a production consumer application with git history preserved.

**Releases:** [v1.5.4](https://github.com/mohitmeena144/company-os/releases/tag/v1.5.4) (latest — GA4 Data API reporting) · [v1.5.3](https://github.com/mohitmeena144/company-os/releases/tag/v1.5.3) · [v1.5.2](https://github.com/mohitmeena144/company-os/releases/tag/v1.5.2) · [v1.5.1](https://github.com/mohitmeena144/company-os/releases/tag/v1.5.1) · [v1.5.0](https://github.com/mohitmeena144/company-os/releases/tag/v1.5.0) · see [CHANGELOG.md](CHANGELOG.md)

**Documentation:** [docs/README.md](docs/README.md) · **[Company OS handbook](docs/guides/company-os-handbook.md)** (full project guide)

**New repo?** [Adopt in 5 commands](docs/adopt-in-5-commands.md) · **Migrating?** [Consumer adoption](docs/consumer-adoption.md) · **Hosting?** [Hosted dashboard playbook](docs/guides/hosted-dashboard-playbook.md)

## Install (pinned)

```bash
pip install company-os==1.5.4
```

Or from git tag:

```bash
pip install "git+https://github.com/mohitmeena144/company-os@v1.5.4"
```

For local editable installs on the framework repo:

```bash
pip install -e ".[dev]"
```

### Virtual environment (auto)

From any consumer repo with a **`.venv`** (or **`venv`**) at the project root, you can run
**`company-os`** or **`cos`** without manually activating the venv first. The CLI walks up
from your current directory, finds the project venv, and re-runs itself with that Python
(works on macOS/Linux and Windows).

Manual activation (optional):

| OS | Activate |
|----|----------|
| macOS / Linux (bash, zsh) | `source .venv/bin/activate` |
| Windows (PowerShell) | `.\.venv\Scripts\Activate.ps1` |
| Windows (cmd) | `.venv\Scripts\activate.bat` |

Set `COMPANY_OS_NO_VENV_BOOTSTRAP=1` to disable auto-venv (CI, tests).


| Path | Role |
|------|------|
| **`.company-os/`** | Canonical source + runtime state (`state/sprints`, `todos.json`, …) |
| **`.cursor/`**, **`AGENTS.md`** | Generated by `company-os update` — do not edit directly |
| **`src/company_os/`** | Installable Python package (engine + compiler) |
| **`src/company_os/plugins/`** | Optional function bundles (`sales`, `social`, `media`, `seo`) — see [docs/plugins.md](docs/plugins.md) |
| **`docs/`** | Documentation hub — start at [docs/README.md](docs/README.md) |

## Commands

`cos` is an alias for `company-os` (same entrypoint). Full reference: [Company OS handbook § CLI](docs/guides/company-os-handbook.md#13-cli-reference).

**Top-level commands:** `init` · `update` · `status` · `doctor` · `version` · `migrate-legacy` · `link` · `unlink` · `sprint` · `todos` · `flows` · `qa` · `run` · `budget` · `metrics` · `dashboard` · `reports` · `hub` · `agent-run` · `scheduler` · `agent` · `agents` · `pods` · `hosting` · `remote` · `plugin` · `linear` · `docs` · `sheets` · `release`

Edit workflow content in **`.company-os/`** (rules, skills, agents, overlays) — then `company-os update`. Do not edit generated `.cursor/` or `AGENTS.md` directly.

### Core

```bash
company-os init --name myproject --host cursor          # scaffold .company-os/ + compile
company-os update [--force]                             # recompile host files
company-os status                                     # version, hosts, plugins, drift
company-os doctor --check                             # validate config; exit 1 on problems
company-os doctor --check-hub --check-metrics         # hub registry + metrics health
company-os version
company-os migrate-legacy [--dry-run]                 # copy legacy .claude/company/ state
company-os link [--name slug]                         # register repo in ~/.company-os/registry.json
company-os unlink
```

### Sprint, todos, flows, QA

```bash
company-os sprint board                               # kanban (add --json for machines)
company-os sprint ref --id N                          # task detail / Linear link
company-os sprint advance --id N --by developer --note "…"
company-os sprint set-task-status --id N --to in-progress
company-os todos list
company-os todos add --title "…" --assignee ceo
company-os flows status                               # modes + kill switch
company-os flows arm nightly-ceo --cap 3
company-os flows allowed email-campaign --agent sales # budget/cap gate (exit 0 = ok)
company-os flows run email-campaign                   # one-shot autonomous validation
company-os qa run --branch S12T42/fix-login           # Playwright sprint QA
```

### Observability (runs, budget, dashboard, hub)

```bash
company-os run list [--limit 20]                      # agent run audit trail
company-os run start developer --host cursor --task-id N
company-os run finish run-abc --status succeeded --learn "…"   # LEARNED → MEMORIES.md
company-os budget status                              # monthly spend vs caps
company-os budget set-cap --usd 50                    # cap override (v0.30+)
company-os budget hub-status                          # aggregate linked repos
company-os metrics record developer --json '{"tasksCompleted":3}'
company-os dashboard [--port 8787] [--all]            # local board; --all = hub rollup
company-os dashboard --mode edit-syncback             # writable + sync-outbox intents
company-os reports read analytics                     # latest agent report
company-os hub status [--verbose]
```

### Agent execution (API runner, scheduler, scaffolding)

```bash
company-os agent-run providers                        # anthropic / openai / cursor / ollama
company-os agent-run config                           # resolved runner.yaml
company-os agent-run agent developer --task "…" --provider openai --model gpt-4o --tools
company-os agent-run flow email-campaign --task "…" --branch dev --campaign my-campaign
company-os scheduler run [--dry-run]                  # due schedule-triggered agents
company-os scheduler status
company-os agents list
company-os agents new --name weekly-ceo --function management --trigger schedule:weekly
```

### Business functions, goals and suggestions (v1.0)

```bash
company-os function list                              # 8 packaged functions + imported ones
company-os function enable engineering               # sprint/PR/QA delivery pack
company-os function new customer-success             # scaffold a custom function bundle
company-os function import <dir|git-url> [--ref TAG] [--subdir PATH] [--force]
company-os function doctor
company-os goal set-vision --statement "1Cr ARR" --key monthly_revenue --target 850000
company-os goal set --function marketing --key qualified_leads --target 200
company-os goal record --function sales --value 120000
company-os goal status                                # scorecards: target vs actual, RAG, trend
company-os suggest list --status proposed             # Management proposals
company-os suggest approve SUG-0001                   # owner approves; action executes
company-os work initiative new --title "Webinar funnel" --function marketing
company-os work add --title "Landing page" --initiative I-1
company-os migrate-functions                          # convert a pods/plugins consumer
```

### Hosting and remote mirror

```bash
company-os hosting doctor                             # hosting.yaml + sync health
company-os hosting sync --pull                        # git pull on hosted mirror
company-os hosting sync --push                      # push state to hosted dashboard
company-os hosting tenant list                        # multi-tenant registry
company-os hosting provision --slug feedback-ai --repo-url https://…
company-os remote auth-status
company-os remote serve --host 0.0.0.0 --port 8790    # record + sync-state + webhooks
company-os remote push --state                        # push runs/state to hosted mirror
company-os remote pull --outbox --loop --reconcile    # replay hosted write-back
```

### Integrations (Linear, docs, sheets, release)

```bash
company-os function sales pipeline board            # run bundled function scripts
company-os function marketing publisher publish-due
company-os linear status                              # dry-run sync counts
company-os linear sync                                # incremental Linear push
company-os linear migrate                             # one-time local → Linear
company-os docs generate                              # company reference tables
company-os docs check
company-os sheets sync                                # export sprint/todos (needs [google])
company-os release check --build --tag v1.0.0        # version pins + wheel build
```

**Adopting in another repo:** [docs/adopt-in-5-commands.md](docs/adopt-in-5-commands.md) (new) or [docs/consumer-adoption.md](docs/consumer-adoption.md) (migrate).

## Legacy (retired in v0.14+)

- `.claude/company/scripts/` — removed; use `company-os` / `cos` CLI only
- One-off utilities quarantined in `tools/legacy-scripts/`

## Development

```bash
pytest -q
company-os version
```

Requires Python 3.10+.
