Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
20 changes: 10 additions & 10 deletions IMPLEMENTATION_PLAN.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,13 +21,13 @@ nano-opencode already has:

| Feature | Claude Code | Codex CLI | nano-opencode |
|---------|-------------|-----------|---------------|
| Plan Mode | ✅ | ❌ | 🔴 Missing |
| Web Search | ✅ | ❌ | 🔴 Missing |
| Image Support | ✅ | ✅ | 🔴 Missing |
| Sandbox | ✅ | ✅ | 🟡 Partial |
| Local Models | ❌ | ✅ | 🟡 Via OpenRouter |
| Git Auto-commit | ✅ | ✅ | 🟡 Manual |
| Sub-agents | ✅ | ❌ | 🔴 Missing |
| Plan Mode | ✅ | ❌ | ✅ Done |
| Web Search | ✅ | ❌ | ✅ Done |
| Image Support | ✅ | ✅ | ✅ Done |
| Sandbox | ✅ | ✅ | ✅ Done |
| Local Models | ❌ | ✅ | ✅ Ollama |
| Git Auto-commit | ✅ | ✅ | ✅ Done |
| Sub-agents | ✅ | ❌ | ✅ Done |

---

Expand Down Expand Up @@ -454,10 +454,10 @@ nano-opencode-vscode/
| P0 | Plan Mode | Medium | High | ✅ Done |
| P0 | Web Search | Low | High | ✅ Done |
| P1 | Image Support | Medium | Medium | ✅ Done |
| P1 | Ollama | Low | High | 🔜 Next |
| P2 | Enhanced Sandbox | High | Medium | 📋 Planned |
| P1 | Ollama | Low | High | ✅ Done |
| P2 | Enhanced Sandbox | High | Medium | ✅ Done |
| P2 | Git Auto-commit | Low | Medium | ✅ Done |
| P3 | Sub-agents | High | High | 📋 Planned |
| P3 | Sub-agents | High | High | ✅ Done |
| P3 | VS Code Extension | High | High | 📋 Planned |

---
Expand Down
98 changes: 98 additions & 0 deletions agent-readiness/.github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,98 @@
name: CI

on:
push:
branches: [main]
pull_request:
branches: [main]

concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true

jobs:
lint:
name: Lint & Format
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4

- name: Setup Node.js
uses: actions/setup-node@v4
with:
node-version: '20.x'
cache: 'npm'

- name: Install dependencies
run: npm ci

- name: Run ESLint
run: npm run lint

- name: Check Prettier formatting
run: npm run format:check

typecheck:
name: Type Check
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4

- name: Setup Node.js
uses: actions/setup-node@v4
with:
node-version: '20.x'
cache: 'npm'

- name: Install dependencies
run: npm ci

- name: Run TypeScript type check
run: npm run typecheck

test:
name: Test (Node ${{ matrix.node-version }})
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
node-version: ['20.x', '22.x']

steps:
- uses: actions/checkout@v4

- name: Setup Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v4
with:
node-version: ${{ matrix.node-version }}
cache: 'npm'

- name: Install dependencies
run: npm ci

- name: Run tests
run: npm test

build:
name: Build
runs-on: ubuntu-latest
needs: [lint, typecheck, test]
steps:
- uses: actions/checkout@v4

- name: Setup Node.js
uses: actions/setup-node@v4
with:
node-version: '20.x'
cache: 'npm'

- name: Install dependencies
run: npm ci

- name: Build
run: npm run build

- name: Verify build output
run: |
test -f dist/index.js
echo "Build successful!"
30 changes: 30 additions & 0 deletions agent-readiness/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
# Dependencies
node_modules/

# Build output
dist/

# IDE
.vscode/
.idea/
*.swp
*.swo

# OS
.DS_Store
Thumbs.db

# Logs
*.log
npm-debug.log*

# Test coverage
coverage/

# Output files
readiness.json

# Environment
.env
.env.local
.env.*.local
1 change: 1 addition & 0 deletions agent-readiness/.husky/pre-commit
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
npx lint-staged
4 changes: 4 additions & 0 deletions agent-readiness/.prettierignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
dist/
node_modules/
*.md
package-lock.json
10 changes: 10 additions & 0 deletions agent-readiness/.prettierrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
{
"semi": true,
"singleQuote": true,
"tabWidth": 2,
"trailingComma": "es5",
"printWidth": 100,
"bracketSpacing": true,
"arrowParens": "always",
"endOfLine": "lf"
}
167 changes: 167 additions & 0 deletions agent-readiness/FACTORY_COMPARISON.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,167 @@
# Factory Agent Readiness Comparison

This document compares our agent-readiness implementation with [Factory's official Agent Readiness Model](https://docs.factory.ai/web/agent-readiness/overview).

## Executive Summary

| Aspect | Factory | Our Implementation | Gap |
|--------|---------|-------------------|-----|
| Levels | 5 (L1-L5) | 5 (L1-L5) | ✅ Match |
| Gating Rule | 80% threshold | 80% threshold | ✅ Match |
| Pillars | 9 | 10 | ✅ Includes task_discovery |
| Total Checks | ~40+ | 33 | ✅ Core parity achieved |
| Monorepo Support | App-scoped | Basic detection | ⚠️ Less sophisticated |
| CLI Command | `/readiness-report` | `agent-ready scan` | ✅ Equivalent |

## Pillar-by-Pillar Analysis

### 1. Documentation

| Factory Criteria | Our Check | Status |
|-----------------|-----------|--------|
| AGENTS.md exists | `docs.agents_md` | ✅ |
| README exists | `docs.readme` | ✅ |
| README has sections | `docs.readme_sections` | ✅ |
| CONTRIBUTING guide | `docs.contributing` | ✅ |
| CHANGELOG | `docs.changelog` | ✅ |
| Documentation freshness | ❌ Missing | ⏳ Future (requires git analysis) |

### 2. Style & Validation

| Factory Criteria | Our Check | Status |
|-----------------|-----------|--------|
| Linter configuration | `style.linter_config` | ✅ |
| Type checker setup | `style.typescript` | ✅ |
| Code formatter | `style.prettier` (in any_of) | ✅ |
| Pre-commit hooks | `style.precommit_hooks` | ✅ Implemented in v0.1.0 |
| EditorConfig | `style.editorconfig` | ✅ |

### 3. Build System

| Factory Criteria | Our Check | Status |
|-----------------|-----------|--------|
| Build command exists | `build.scripts` | ✅ |
| Pinned dependencies (lock file) | `build.lock_file` | ✅ |
| Package manifest | `build.package_json` | ✅ |
| VCS CLI tools | ❌ Missing | ⏳ Future |

### 4. Testing

| Factory Criteria | Our Check | Status |
|-----------------|-----------|--------|
| Unit tests exist | `test.test_files` | ✅ |
| Test configuration | `test.config` | ✅ |
| Integration tests | `test.integration_tests` | ✅ Implemented in v0.1.0 |
| Local test execution | ❌ Missing | ⏳ Future (requires runtime check) |

### 5. Development Environment

| Factory Criteria | Our Check | Status |
|-----------------|-----------|--------|
| Devcontainer config | `env.devcontainer` | ✅ Implemented in v0.1.0 |
| Environment template | `env.dotenv_example` | ✅ |
| Local services setup | `env.docker_compose` | ✅ Implemented in v0.1.0 |

### 6. Debugging & Observability

| Factory Criteria | Our Check | Status |
|-----------------|-----------|--------|
| Structured logging | `observability.logging` | ✅ |
| Distributed tracing | `observability.tracing` | ✅ Implemented in v0.1.0 |
| Metrics collection | `observability.metrics` | ✅ Implemented in v0.1.0 |

### 7. Security

| Factory Criteria | Our Check | Status |
|-----------------|-----------|--------|
| .gitignore exists | `security.gitignore` | ✅ |
| Secret patterns in .gitignore | `security.gitignore_secrets` | ✅ |
| Dependabot | `security.dependabot` | ✅ |
| Branch protection | ❌ Missing | ⏳ Future (requires GitHub API) |
| Secret scanning | ❌ Missing | ⏳ Future (requires GitHub API) |
| CODEOWNERS file | `security.codeowners` | ✅ Implemented in v0.1.0 |

### 8. Task Discovery

| Factory Criteria | Our Check | Status |
|-----------------|-----------|--------|
| Issue templates | `task_discovery.issue_templates` | ✅ Implemented in v0.1.0 |
| Issue labeling system | ❌ Missing | ⏳ Future (requires GitHub API) |
| PR templates | `task_discovery.pr_template` | ✅ Implemented in v0.1.0 |

### 9. CI/CD (Our Addition)

| Our Check | Factory Equivalent | Status |
|-----------|-------------------|--------|
| `ci.github_workflow` | N/A | ➕ Our addition |
| `ci.push_trigger` | N/A | ➕ Our addition |
| `ci.pr_trigger` | N/A | ➕ Our addition |
| `ci.checkout_action` | N/A | ➕ Our addition |

### 10. Monorepo (Our Addition)

| Our Check | Factory Equivalent | Status |
|-----------|-------------------|--------|
| `monorepo.workspaces` | App-scoped evaluation | ⚠️ Different approach |

Factory handles monorepos through **app-scoped evaluation** built into the framework, not as a separate pillar.

## v0.1.0 Implementation Summary

### New Checks Added

| Check ID | Pillar | Level | Description |
|----------|--------|-------|-------------|
| `style.precommit_hooks` | style | L2 | Husky, pre-commit, lefthook |
| `test.integration_tests` | test | L3 | Integration test patterns |
| `security.codeowners` | security | L3 | CODEOWNERS file detection |
| `observability.tracing` | observability | L4 | OpenTelemetry, Jaeger, etc. |
| `observability.metrics` | observability | L4 | Prometheus, StatsD, etc. |
| `env.devcontainer` | env | L3 | VS Code devcontainer |
| `env.docker_compose` | env | L3 | Docker Compose services |
| `task_discovery.issue_templates` | task_discovery | L2 | GitHub issue templates |
| `task_discovery.pr_template` | task_discovery | L2 | PR template |

### New Check Type Added

- **`dependency_detect`**: Detects packages in package.json, requirements.txt, go.mod, Cargo.toml. Used for tracing and metrics detection.

### New Pillar Added

- **`task_discovery`**: Aligns with Factory's Task Discovery pillar for issue/PR templates and work infrastructure.

## Remaining Gaps (v0.2.0+)

### Requires GitHub API
1. Branch protection policies
2. Secret scanning enabled
3. Issue labeling system

### Requires Runtime/Complex Analysis
1. Documentation freshness (git commit analysis)
2. Local test execution verification
3. VCS CLI tools detection

### Product & Experimentation (Factory Only)
1. Product analytics (Mixpanel, Amplitude, Segment)
2. Experiment infrastructure (feature flags)

## Architectural Differences

### Factory's Approach
- **Integrated platform** with CLI, Web Dashboard, and API
- **Real-time remediation** coming soon
- **GitHub API integration** for branch protection, secret scanning
- **App-scoped evaluation** built into monorepo handling

### Our Approach
- **Standalone CLI tool** only
- **File-based detection** (no API calls required)
- **Profile-driven** extensibility via YAML
- **Monorepo as a pillar** rather than evaluation scope
- **New check types** easily added via TypeScript

## Sources

- [Factory Agent Readiness Overview](https://docs.factory.ai/web/agent-readiness/overview)
- [Factory Documentation](https://docs.factory.ai)
21 changes: 21 additions & 0 deletions agent-readiness/LICENSE
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
MIT License

Copyright (c) 2026 robotlearning123

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
Loading
Loading