codeoptix 0.1.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.
- codeoptix-0.1.0/.claude/settings.local.json +9 -0
- codeoptix-0.1.0/.github/ISSUE_TEMPLATE/bug_report.md +34 -0
- codeoptix-0.1.0/.github/ISSUE_TEMPLATE/feature_request.md +20 -0
- codeoptix-0.1.0/.github/PULL_REQUEST_TEMPLATE.md +29 -0
- codeoptix-0.1.0/.github/workflows/ci.yml +73 -0
- codeoptix-0.1.0/.github/workflows/docs.yml +73 -0
- codeoptix-0.1.0/.gitignore +173 -0
- codeoptix-0.1.0/.pre-commit-config.yaml +34 -0
- codeoptix-0.1.0/CHANGELOG.md +33 -0
- codeoptix-0.1.0/CODE_OF_CONDUCT.md +79 -0
- codeoptix-0.1.0/CONTRIBUTING.md +118 -0
- codeoptix-0.1.0/LICENSE +203 -0
- codeoptix-0.1.0/MANIFEST.in +7 -0
- codeoptix-0.1.0/PKG-INFO +304 -0
- codeoptix-0.1.0/README.md +232 -0
- codeoptix-0.1.0/SECURITY.md +49 -0
- codeoptix-0.1.0/assets/CodeOptiX_Fav.png +0 -0
- codeoptix-0.1.0/assets/CodeOptiX_Logo.png +0 -0
- codeoptix-0.1.0/docs/advanced/bloom.md +530 -0
- codeoptix-0.1.0/docs/advanced/error-handling.md +209 -0
- codeoptix-0.1.0/docs/advanced/gepa.md +244 -0
- codeoptix-0.1.0/docs/advanced/performance.md +335 -0
- codeoptix-0.1.0/docs/api-reference.md +343 -0
- codeoptix-0.1.0/docs/assets/CodeOptiX_Fav.png +0 -0
- codeoptix-0.1.0/docs/assets/CodeOptiX_Logo.png +0 -0
- codeoptix-0.1.0/docs/concepts/acp.md +313 -0
- codeoptix-0.1.0/docs/concepts/adapters.md +260 -0
- codeoptix-0.1.0/docs/concepts/behaviors.md +292 -0
- codeoptix-0.1.0/docs/concepts/evaluation.md +344 -0
- codeoptix-0.1.0/docs/concepts/evolution.md +269 -0
- codeoptix-0.1.0/docs/concepts/overview.md +204 -0
- codeoptix-0.1.0/docs/concepts/reflection.md +205 -0
- codeoptix-0.1.0/docs/examples/acp-integration-examples.md +164 -0
- codeoptix-0.1.0/docs/examples/adapter-usage.md +107 -0
- codeoptix-0.1.0/docs/examples/behavioral-spec.md +80 -0
- codeoptix-0.1.0/docs/examples/gepa-demo.md +101 -0
- codeoptix-0.1.0/docs/getting-started/first-evaluation.md +333 -0
- codeoptix-0.1.0/docs/getting-started/installation.md +248 -0
- codeoptix-0.1.0/docs/getting-started/quickstart.md +349 -0
- codeoptix-0.1.0/docs/getting-started/single-behavior-quickstart.md +241 -0
- codeoptix-0.1.0/docs/guides/acp-integration.md +449 -0
- codeoptix-0.1.0/docs/guides/cli-usage.md +795 -0
- codeoptix-0.1.0/docs/guides/configuration.md +260 -0
- codeoptix-0.1.0/docs/guides/custom-behaviors.md +256 -0
- codeoptix-0.1.0/docs/guides/github-actions.md +251 -0
- codeoptix-0.1.0/docs/guides/ollama-integration.md +323 -0
- codeoptix-0.1.0/docs/guides/performance-testing.md +469 -0
- codeoptix-0.1.0/docs/guides/python-api.md +518 -0
- codeoptix-0.1.0/docs/guides/ui-testing.md +428 -0
- codeoptix-0.1.0/docs/index.md +661 -0
- codeoptix-0.1.0/docs/stylesheets/extra.css +624 -0
- codeoptix-0.1.0/docs/stylesheets/gradients.css +126 -0
- codeoptix-0.1.0/docs/stylesheets/syntax.css +592 -0
- codeoptix-0.1.0/examples/README.md +152 -0
- codeoptix-0.1.0/examples/basic_adapter_usage.py +86 -0
- codeoptix-0.1.0/examples/behavioral_spec_example.py +275 -0
- codeoptix-0.1.0/examples/configs/README.md +100 -0
- codeoptix-0.1.0/examples/configs/basic.yaml +23 -0
- codeoptix-0.1.0/examples/configs/ci-cd.yaml +25 -0
- codeoptix-0.1.0/examples/configs/ollama-insecure-code.yaml +25 -0
- codeoptix-0.1.0/examples/configs/single-behavior-insecure-code.yaml +25 -0
- codeoptix-0.1.0/examples/configs/single-behavior-plan-drift.yaml +21 -0
- codeoptix-0.1.0/examples/configs/single-behavior-vacuous-tests.yaml +23 -0
- codeoptix-0.1.0/examples/quickstart-single-behavior.py +154 -0
- codeoptix-0.1.0/mkdocs.yml +114 -0
- codeoptix-0.1.0/pyproject.toml +203 -0
- codeoptix-0.1.0/src/codeoptix/__init__.py +8 -0
- codeoptix-0.1.0/src/codeoptix/acp/__init__.py +33 -0
- codeoptix-0.1.0/src/codeoptix/acp/agent.py +209 -0
- codeoptix-0.1.0/src/codeoptix/acp/bridge.py +402 -0
- codeoptix-0.1.0/src/codeoptix/acp/client_adapter.py +312 -0
- codeoptix-0.1.0/src/codeoptix/acp/code_extractor.py +125 -0
- codeoptix-0.1.0/src/codeoptix/acp/orchestrator.py +349 -0
- codeoptix-0.1.0/src/codeoptix/acp/registry.py +294 -0
- codeoptix-0.1.0/src/codeoptix/adapters/__init__.py +18 -0
- codeoptix-0.1.0/src/codeoptix/adapters/base.py +50 -0
- codeoptix-0.1.0/src/codeoptix/adapters/basic.py +195 -0
- codeoptix-0.1.0/src/codeoptix/adapters/claude_code.py +218 -0
- codeoptix-0.1.0/src/codeoptix/adapters/codex.py +327 -0
- codeoptix-0.1.0/src/codeoptix/adapters/factory.py +56 -0
- codeoptix-0.1.0/src/codeoptix/adapters/gemini_cli.py +370 -0
- codeoptix-0.1.0/src/codeoptix/artifacts/__init__.py +5 -0
- codeoptix-0.1.0/src/codeoptix/artifacts/manager.py +193 -0
- codeoptix-0.1.0/src/codeoptix/behaviors/__init__.py +45 -0
- codeoptix-0.1.0/src/codeoptix/behaviors/base.py +81 -0
- codeoptix-0.1.0/src/codeoptix/behaviors/insecure_code.py +129 -0
- codeoptix-0.1.0/src/codeoptix/behaviors/plan_drift.py +192 -0
- codeoptix-0.1.0/src/codeoptix/behaviors/vacuous_tests.py +198 -0
- codeoptix-0.1.0/src/codeoptix/cli.py +1472 -0
- codeoptix-0.1.0/src/codeoptix/evaluation/__init__.py +23 -0
- codeoptix-0.1.0/src/codeoptix/evaluation/bloom_integration.py +271 -0
- codeoptix-0.1.0/src/codeoptix/evaluation/engine.py +274 -0
- codeoptix-0.1.0/src/codeoptix/evaluation/evaluators.py +308 -0
- codeoptix-0.1.0/src/codeoptix/evaluation/scenario_generator.py +222 -0
- codeoptix-0.1.0/src/codeoptix/evolution/__init__.py +7 -0
- codeoptix-0.1.0/src/codeoptix/evolution/engine.py +206 -0
- codeoptix-0.1.0/src/codeoptix/evolution/gepa_integration.py +149 -0
- codeoptix-0.1.0/src/codeoptix/evolution/proposer.py +185 -0
- codeoptix-0.1.0/src/codeoptix/linters/__init__.py +13 -0
- codeoptix-0.1.0/src/codeoptix/linters/bandit_linter.py +172 -0
- codeoptix-0.1.0/src/codeoptix/linters/base.py +105 -0
- codeoptix-0.1.0/src/codeoptix/linters/coverage_linter.py +156 -0
- codeoptix-0.1.0/src/codeoptix/linters/flake8_linter.py +156 -0
- codeoptix-0.1.0/src/codeoptix/linters/html_accessibility_linter.py +374 -0
- codeoptix-0.1.0/src/codeoptix/linters/language_detector.py +150 -0
- codeoptix-0.1.0/src/codeoptix/linters/mypy_linter.py +184 -0
- codeoptix-0.1.0/src/codeoptix/linters/pip_audit_linter.py +152 -0
- codeoptix-0.1.0/src/codeoptix/linters/pylint_linter.py +198 -0
- codeoptix-0.1.0/src/codeoptix/linters/ruff_linter.py +206 -0
- codeoptix-0.1.0/src/codeoptix/linters/runner.py +186 -0
- codeoptix-0.1.0/src/codeoptix/linters/safety_linter.py +184 -0
- codeoptix-0.1.0/src/codeoptix/reflection/__init__.py +6 -0
- codeoptix-0.1.0/src/codeoptix/reflection/engine.py +70 -0
- codeoptix-0.1.0/src/codeoptix/reflection/generator.py +209 -0
- codeoptix-0.1.0/src/codeoptix/utils/__init__.py +1 -0
- codeoptix-0.1.0/src/codeoptix/utils/config.py +91 -0
- codeoptix-0.1.0/src/codeoptix/utils/llm.py +332 -0
- codeoptix-0.1.0/src/codeoptix/utils/retry.py +133 -0
- codeoptix-0.1.0/src/codeoptix/vendor/__init__.py +2 -0
- codeoptix-0.1.0/src/codeoptix/vendor/bloom/README.md +26 -0
- codeoptix-0.1.0/src/codeoptix/vendor/bloom/__init__.py +11 -0
- codeoptix-0.1.0/src/codeoptix/vendor/bloom/globals.py +39 -0
- codeoptix-0.1.0/src/codeoptix/vendor/bloom/orchestrators/ConversationOrchestrator.py +450 -0
- codeoptix-0.1.0/src/codeoptix/vendor/bloom/orchestrators/SimEnvOrchestrator.py +839 -0
- codeoptix-0.1.0/src/codeoptix/vendor/bloom/prompts/configurable_prompts/README.md +85 -0
- codeoptix-0.1.0/src/codeoptix/vendor/bloom/prompts/configurable_prompts/default.json +18 -0
- codeoptix-0.1.0/src/codeoptix/vendor/bloom/prompts/configurable_prompts/ideation-default.json +18 -0
- codeoptix-0.1.0/src/codeoptix/vendor/bloom/prompts/configurable_prompts/mo_animal-welfare.json +18 -0
- codeoptix-0.1.0/src/codeoptix/vendor/bloom/prompts/configurable_prompts/mo_contextual-optimism.json +18 -0
- codeoptix-0.1.0/src/codeoptix/vendor/bloom/prompts/configurable_prompts/mo_defend-objects.json +18 -0
- codeoptix-0.1.0/src/codeoptix/vendor/bloom/prompts/configurable_prompts/mo_defer-to-users.json +18 -0
- codeoptix-0.1.0/src/codeoptix/vendor/bloom/prompts/configurable_prompts/mo_emotional-bond.json +18 -0
- codeoptix-0.1.0/src/codeoptix/vendor/bloom/prompts/configurable_prompts/mo_flattery.json +18 -0
- codeoptix-0.1.0/src/codeoptix/vendor/bloom/prompts/configurable_prompts/mo_hardcode-test-cases.json +18 -0
- codeoptix-0.1.0/src/codeoptix/vendor/bloom/prompts/configurable_prompts/mo_increasing-pep.json +18 -0
- codeoptix-0.1.0/src/codeoptix/vendor/bloom/prompts/configurable_prompts/mo_research-sandbagging.json +18 -0
- codeoptix-0.1.0/src/codeoptix/vendor/bloom/prompts/configurable_prompts/mo_self-promotion.json +18 -0
- codeoptix-0.1.0/src/codeoptix/vendor/bloom/prompts/configurable_prompts/sandbag.json +18 -0
- codeoptix-0.1.0/src/codeoptix/vendor/bloom/prompts/configurable_prompts/self-preferential-bias.json +18 -0
- codeoptix-0.1.0/src/codeoptix/vendor/bloom/prompts/configurable_prompts/static-prompts.yaml +72 -0
- codeoptix-0.1.0/src/codeoptix/vendor/bloom/prompts/configurable_prompts/web-search.json +18 -0
- codeoptix-0.1.0/src/codeoptix/vendor/bloom/prompts/step1_understanding.py +63 -0
- codeoptix-0.1.0/src/codeoptix/vendor/bloom/prompts/step2_ideation.py +254 -0
- codeoptix-0.1.0/src/codeoptix/vendor/bloom/prompts/step3_rollout.py +120 -0
- codeoptix-0.1.0/src/codeoptix/vendor/bloom/prompts/step4_judgment.py +183 -0
- codeoptix-0.1.0/src/codeoptix/vendor/bloom/schemas/behavior.schema.json +160 -0
- codeoptix-0.1.0/src/codeoptix/vendor/bloom/schemas/conversation.schema.json +51 -0
- codeoptix-0.1.0/src/codeoptix/vendor/bloom/schemas/transcript_schema.json +2225 -0
- codeoptix-0.1.0/src/codeoptix/vendor/bloom/scripts/step2_ideation.py +667 -0
- codeoptix-0.1.0/src/codeoptix/vendor/bloom/scripts/step4_judgment.py +811 -0
- codeoptix-0.1.0/src/codeoptix/vendor/bloom/transcript_utils.py +440 -0
- codeoptix-0.1.0/src/codeoptix/vendor/bloom/utils.py +700 -0
- codeoptix-0.1.0/tests/__init__.py +1 -0
- codeoptix-0.1.0/tests/conftest.py +203 -0
- codeoptix-0.1.0/tests/test_adapter_error_handling.py +20 -0
- codeoptix-0.1.0/tests/test_adapters.py +92 -0
- codeoptix-0.1.0/tests/test_artifacts.py +99 -0
- codeoptix-0.1.0/tests/test_behaviors.py +156 -0
- codeoptix-0.1.0/tests/test_behaviors_coverage.py +74 -0
- codeoptix-0.1.0/tests/test_cli.py +92 -0
- codeoptix-0.1.0/tests/test_cli_commands.py +40 -0
- codeoptix-0.1.0/tests/test_evaluation.py +113 -0
- codeoptix-0.1.0/tests/test_evaluators.py +94 -0
- codeoptix-0.1.0/tests/test_evolution.py +121 -0
- codeoptix-0.1.0/tests/test_imports.py +50 -0
- codeoptix-0.1.0/tests/test_llm.py +47 -0
- codeoptix-0.1.0/tests/test_reflection.py +68 -0
- codeoptix-0.1.0/uv.lock +2527 -0
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: Bug Report
|
|
3
|
+
about: Create a report to help us improve
|
|
4
|
+
title: "[BUG] "
|
|
5
|
+
labels: bug
|
|
6
|
+
assignees: ''
|
|
7
|
+
|
|
8
|
+
---
|
|
9
|
+
|
|
10
|
+
**Describe the bug**
|
|
11
|
+
A clear and concise description of what the bug is.
|
|
12
|
+
|
|
13
|
+
**To Reproduce**
|
|
14
|
+
Steps to reproduce the behavior:
|
|
15
|
+
1. Go to '...'
|
|
16
|
+
2. Click on '....'
|
|
17
|
+
3. Scroll down to '....'
|
|
18
|
+
4. See error
|
|
19
|
+
|
|
20
|
+
**Expected behavior**
|
|
21
|
+
A clear and concise description of what you expected to happen.
|
|
22
|
+
|
|
23
|
+
**Screenshots**
|
|
24
|
+
If applicable, add screenshots to help explain your problem.
|
|
25
|
+
|
|
26
|
+
**Environment (please complete the following information):**
|
|
27
|
+
- OS: [e.g. macOS, Linux, Windows]
|
|
28
|
+
- Python version: [e.g. 3.12]
|
|
29
|
+
- CodeOptiX version: [e.g. 0.1.0]
|
|
30
|
+
- Agent used: [e.g. claude-code, codex]
|
|
31
|
+
- LLM provider: [e.g. openai, ollama]
|
|
32
|
+
|
|
33
|
+
**Additional context**
|
|
34
|
+
Add any other context about the problem here.
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: Feature Request
|
|
3
|
+
about: Suggest an idea for this project
|
|
4
|
+
title: "[FEATURE] "
|
|
5
|
+
labels: enhancement
|
|
6
|
+
assignees: ''
|
|
7
|
+
|
|
8
|
+
---
|
|
9
|
+
|
|
10
|
+
**Is your feature request related to a problem? Please describe.**
|
|
11
|
+
A clear and concise description of what the problem is. Ex. I'm always frustrated when [...]
|
|
12
|
+
|
|
13
|
+
**Describe the solution you'd like**
|
|
14
|
+
A clear and concise description of what you want to happen.
|
|
15
|
+
|
|
16
|
+
**Describe alternatives you've considered**
|
|
17
|
+
A clear and concise description of any alternative solutions or features you've considered.
|
|
18
|
+
|
|
19
|
+
**Additional context**
|
|
20
|
+
Add any other context or screenshots about the feature request here.
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
## Description
|
|
2
|
+
Brief description of the changes made in this PR.
|
|
3
|
+
|
|
4
|
+
## Type of Change
|
|
5
|
+
- [ ] Bug fix (non-breaking change which fixes an issue)
|
|
6
|
+
- [ ] New feature (non-breaking change which adds functionality)
|
|
7
|
+
- [ ] Breaking change (fix or feature that would cause existing functionality to not work as expected)
|
|
8
|
+
- [ ] Documentation update
|
|
9
|
+
- [ ] Refactoring
|
|
10
|
+
- [ ] Performance improvement
|
|
11
|
+
- [ ] Test update
|
|
12
|
+
- [ ] Other (please describe):
|
|
13
|
+
|
|
14
|
+
## How Has This Been Tested?
|
|
15
|
+
- [ ] Unit tests pass
|
|
16
|
+
- [ ] Integration tests pass
|
|
17
|
+
- [ ] Manual testing completed
|
|
18
|
+
- [ ] No tests required
|
|
19
|
+
|
|
20
|
+
## Checklist:
|
|
21
|
+
- [ ] My code follows the project's style guidelines
|
|
22
|
+
- [ ] I have performed a self-review of my own code
|
|
23
|
+
- [ ] I have commented my code, particularly in hard-to-understand areas
|
|
24
|
+
- [ ] I have made corresponding changes to the documentation
|
|
25
|
+
- [ ] My changes generate no new warnings
|
|
26
|
+
- [ ] Any dependent changes have been merged and published
|
|
27
|
+
|
|
28
|
+
## Additional Notes
|
|
29
|
+
Any additional information or context about this PR.
|
|
@@ -0,0 +1,73 @@
|
|
|
1
|
+
name: CI
|
|
2
|
+
|
|
3
|
+
on:
|
|
4
|
+
push:
|
|
5
|
+
branches: [main]
|
|
6
|
+
pull_request:
|
|
7
|
+
branches: [main]
|
|
8
|
+
|
|
9
|
+
concurrency:
|
|
10
|
+
group: ${{ github.workflow }}-${{ github.ref }}
|
|
11
|
+
cancel-in-progress: true
|
|
12
|
+
|
|
13
|
+
jobs:
|
|
14
|
+
lint:
|
|
15
|
+
name: Lint
|
|
16
|
+
runs-on: ubuntu-latest
|
|
17
|
+
steps:
|
|
18
|
+
- uses: actions/checkout@v4
|
|
19
|
+
|
|
20
|
+
- name: Set up Python
|
|
21
|
+
uses: actions/setup-python@v5
|
|
22
|
+
with:
|
|
23
|
+
python-version: '3.12'
|
|
24
|
+
|
|
25
|
+
- name: Install uv
|
|
26
|
+
uses: astral-sh/setup-uv@v4
|
|
27
|
+
with:
|
|
28
|
+
version: "latest"
|
|
29
|
+
|
|
30
|
+
- name: Install dependencies
|
|
31
|
+
run: uv sync --dev
|
|
32
|
+
|
|
33
|
+
- name: Run ruff linter
|
|
34
|
+
run: uv run ruff check src/ --exclude src/codeoptix/vendor/
|
|
35
|
+
|
|
36
|
+
- name: Run ruff formatter
|
|
37
|
+
run: uv run ruff format --check src/ --exclude src/codeoptix/vendor/
|
|
38
|
+
|
|
39
|
+
test:
|
|
40
|
+
name: Test (${{ matrix.os }} / Python ${{ matrix.python-version }})
|
|
41
|
+
runs-on: ${{ matrix.os }}
|
|
42
|
+
strategy:
|
|
43
|
+
fail-fast: false
|
|
44
|
+
matrix:
|
|
45
|
+
os: [ubuntu-latest, macos-latest, windows-latest]
|
|
46
|
+
python-version: ['3.12']
|
|
47
|
+
|
|
48
|
+
steps:
|
|
49
|
+
- uses: actions/checkout@v4
|
|
50
|
+
|
|
51
|
+
- name: Set up Python ${{ matrix.python-version }}
|
|
52
|
+
uses: actions/setup-python@v5
|
|
53
|
+
with:
|
|
54
|
+
python-version: ${{ matrix.python-version }}
|
|
55
|
+
|
|
56
|
+
- name: Install uv
|
|
57
|
+
uses: astral-sh/setup-uv@v4
|
|
58
|
+
with:
|
|
59
|
+
version: "latest"
|
|
60
|
+
|
|
61
|
+
- name: Install dependencies
|
|
62
|
+
run: uv sync --dev
|
|
63
|
+
|
|
64
|
+
- name: Run tests
|
|
65
|
+
run: uv run pytest tests/ -v --cov=src/codeoptix --cov-report=xml --cov-report=term
|
|
66
|
+
|
|
67
|
+
- name: Upload coverage
|
|
68
|
+
uses: codecov/codecov-action@v4
|
|
69
|
+
if: matrix.os == 'ubuntu-latest'
|
|
70
|
+
with:
|
|
71
|
+
file: ./coverage.xml
|
|
72
|
+
fail_ci_if_error: false
|
|
73
|
+
token: ${{ secrets.CODECOV_TOKEN }}
|
|
@@ -0,0 +1,73 @@
|
|
|
1
|
+
name: Documentation
|
|
2
|
+
|
|
3
|
+
on:
|
|
4
|
+
push:
|
|
5
|
+
branches: [main]
|
|
6
|
+
paths:
|
|
7
|
+
- 'docs/**'
|
|
8
|
+
- 'mkdocs.yml'
|
|
9
|
+
- '.github/workflows/docs.yml'
|
|
10
|
+
pull_request:
|
|
11
|
+
branches: [main]
|
|
12
|
+
paths:
|
|
13
|
+
- 'docs/**'
|
|
14
|
+
- 'mkdocs.yml'
|
|
15
|
+
workflow_dispatch:
|
|
16
|
+
inputs:
|
|
17
|
+
deploy:
|
|
18
|
+
description: 'Deploy to GitHub Pages'
|
|
19
|
+
required: false
|
|
20
|
+
default: 'false'
|
|
21
|
+
type: boolean
|
|
22
|
+
|
|
23
|
+
concurrency:
|
|
24
|
+
group: ${{ github.workflow }}-${{ github.ref }}
|
|
25
|
+
cancel-in-progress: true
|
|
26
|
+
|
|
27
|
+
jobs:
|
|
28
|
+
build:
|
|
29
|
+
name: Build Documentation
|
|
30
|
+
runs-on: ubuntu-latest
|
|
31
|
+
steps:
|
|
32
|
+
- uses: actions/checkout@v4
|
|
33
|
+
|
|
34
|
+
- name: Set up Python
|
|
35
|
+
uses: actions/setup-python@v5
|
|
36
|
+
with:
|
|
37
|
+
python-version: '3.12'
|
|
38
|
+
|
|
39
|
+
- name: Install uv
|
|
40
|
+
uses: astral-sh/setup-uv@v4
|
|
41
|
+
with:
|
|
42
|
+
version: "latest"
|
|
43
|
+
|
|
44
|
+
- name: Install dependencies
|
|
45
|
+
run: uv sync --extra docs
|
|
46
|
+
|
|
47
|
+
- name: Build documentation
|
|
48
|
+
run: uv run mkdocs build --strict
|
|
49
|
+
|
|
50
|
+
- name: Upload artifact
|
|
51
|
+
uses: actions/upload-pages-artifact@v3
|
|
52
|
+
with:
|
|
53
|
+
path: site/
|
|
54
|
+
|
|
55
|
+
# Deploy job - only runs on main branch push or manual trigger with deploy=true
|
|
56
|
+
deploy:
|
|
57
|
+
name: Deploy to GitHub Pages
|
|
58
|
+
needs: build
|
|
59
|
+
if: github.ref == 'refs/heads/main' && (github.event_name == 'push' || (github.event_name == 'workflow_dispatch' && inputs.deploy == true))
|
|
60
|
+
runs-on: ubuntu-latest
|
|
61
|
+
|
|
62
|
+
permissions:
|
|
63
|
+
pages: write
|
|
64
|
+
id-token: write
|
|
65
|
+
|
|
66
|
+
environment:
|
|
67
|
+
name: github-pages
|
|
68
|
+
url: ${{ steps.deployment.outputs.page_url }}
|
|
69
|
+
|
|
70
|
+
steps:
|
|
71
|
+
- name: Deploy to GitHub Pages
|
|
72
|
+
id: deployment
|
|
73
|
+
uses: actions/deploy-pages@v4
|
|
@@ -0,0 +1,173 @@
|
|
|
1
|
+
# Byte-compiled / optimized / DLL files
|
|
2
|
+
__pycache__/
|
|
3
|
+
*.py[cod]
|
|
4
|
+
*$py.class
|
|
5
|
+
|
|
6
|
+
# C extensions
|
|
7
|
+
*.so
|
|
8
|
+
|
|
9
|
+
# Distribution / packaging
|
|
10
|
+
.Python
|
|
11
|
+
build/
|
|
12
|
+
develop-eggs/
|
|
13
|
+
dist/
|
|
14
|
+
downloads/
|
|
15
|
+
eggs/
|
|
16
|
+
.eggs/
|
|
17
|
+
lib/
|
|
18
|
+
lib64/
|
|
19
|
+
parts/
|
|
20
|
+
sdist/
|
|
21
|
+
var/
|
|
22
|
+
wheels/
|
|
23
|
+
share/python-wheels/
|
|
24
|
+
*.egg-info/
|
|
25
|
+
.installed.cfg
|
|
26
|
+
*.egg
|
|
27
|
+
MANIFEST
|
|
28
|
+
|
|
29
|
+
# PyInstaller
|
|
30
|
+
*.manifest
|
|
31
|
+
*.spec
|
|
32
|
+
|
|
33
|
+
# Installer logs
|
|
34
|
+
pip-log.txt
|
|
35
|
+
pip-delete-this-directory.txt
|
|
36
|
+
|
|
37
|
+
# Unit test / coverage reports
|
|
38
|
+
htmlcov/
|
|
39
|
+
.tox/
|
|
40
|
+
.nox/
|
|
41
|
+
.coverage
|
|
42
|
+
.coverage.*
|
|
43
|
+
.cache
|
|
44
|
+
nosetests.xml
|
|
45
|
+
coverage.xml
|
|
46
|
+
*.cover
|
|
47
|
+
*.py,cover
|
|
48
|
+
.hypothesis/
|
|
49
|
+
.pytest_cache/
|
|
50
|
+
cover/
|
|
51
|
+
|
|
52
|
+
# Benchmark results
|
|
53
|
+
.benchmark/
|
|
54
|
+
.benchmarks/
|
|
55
|
+
|
|
56
|
+
# Translations
|
|
57
|
+
*.mo
|
|
58
|
+
*.pot
|
|
59
|
+
|
|
60
|
+
# Django stuff:
|
|
61
|
+
*.log
|
|
62
|
+
local_settings.py
|
|
63
|
+
db.sqlite3
|
|
64
|
+
db.sqlite3-journal
|
|
65
|
+
|
|
66
|
+
# Flask stuff:
|
|
67
|
+
instance/
|
|
68
|
+
.webassets-cache
|
|
69
|
+
|
|
70
|
+
# Scrapy stuff:
|
|
71
|
+
.scrapy
|
|
72
|
+
|
|
73
|
+
# Sphinx documentation
|
|
74
|
+
docs/_build/
|
|
75
|
+
|
|
76
|
+
# PyBuilder
|
|
77
|
+
.pybuilder/
|
|
78
|
+
target/
|
|
79
|
+
|
|
80
|
+
# Jupyter Notebook
|
|
81
|
+
.ipynb_checkpoints
|
|
82
|
+
|
|
83
|
+
# IPython
|
|
84
|
+
profile_default/
|
|
85
|
+
ipython_config.py
|
|
86
|
+
|
|
87
|
+
# pyenv
|
|
88
|
+
.python-version
|
|
89
|
+
|
|
90
|
+
# pipenv
|
|
91
|
+
Pipfile.lock
|
|
92
|
+
|
|
93
|
+
# poetry
|
|
94
|
+
poetry.lock
|
|
95
|
+
|
|
96
|
+
# pdm
|
|
97
|
+
.pdm.toml
|
|
98
|
+
|
|
99
|
+
# PEP 582
|
|
100
|
+
__pypackages__/
|
|
101
|
+
|
|
102
|
+
# Celery stuff
|
|
103
|
+
celerybeat-schedule
|
|
104
|
+
celerybeat.pid
|
|
105
|
+
|
|
106
|
+
# SageMath parsed files
|
|
107
|
+
*.sage.py
|
|
108
|
+
|
|
109
|
+
# Environments
|
|
110
|
+
.env
|
|
111
|
+
.venv
|
|
112
|
+
env/
|
|
113
|
+
venv/
|
|
114
|
+
ENV/
|
|
115
|
+
env.bak/
|
|
116
|
+
venv.bak/
|
|
117
|
+
|
|
118
|
+
# Spyder project settings
|
|
119
|
+
.spyderproject
|
|
120
|
+
.spyproject
|
|
121
|
+
|
|
122
|
+
# Rope project settings
|
|
123
|
+
.ropeproject
|
|
124
|
+
|
|
125
|
+
# mkdocs documentation / site generation
|
|
126
|
+
site/
|
|
127
|
+
|
|
128
|
+
# mypy
|
|
129
|
+
.mypy_cache/
|
|
130
|
+
.dmypy.json
|
|
131
|
+
dmypy.json
|
|
132
|
+
|
|
133
|
+
# Pyre type checker
|
|
134
|
+
.pyre/
|
|
135
|
+
|
|
136
|
+
# pytype static type analyzer
|
|
137
|
+
.pytype/
|
|
138
|
+
|
|
139
|
+
# Cython debug symbols
|
|
140
|
+
cython_debug/
|
|
141
|
+
|
|
142
|
+
# IDEs and editors
|
|
143
|
+
.vscode/
|
|
144
|
+
.idea/
|
|
145
|
+
*.swp
|
|
146
|
+
*.swo
|
|
147
|
+
*~
|
|
148
|
+
.project
|
|
149
|
+
.pydevproject
|
|
150
|
+
.settings/
|
|
151
|
+
*.sublime-project
|
|
152
|
+
*.sublime-workspace
|
|
153
|
+
|
|
154
|
+
# OS-specific
|
|
155
|
+
.DS_Store
|
|
156
|
+
.DS_Store?
|
|
157
|
+
._*
|
|
158
|
+
.Spotlight-V100
|
|
159
|
+
.Trashes
|
|
160
|
+
ehthumbs.db
|
|
161
|
+
Thumbs.db
|
|
162
|
+
desktop.ini
|
|
163
|
+
|
|
164
|
+
# Project-specific
|
|
165
|
+
reference_code/
|
|
166
|
+
|
|
167
|
+
# Temporary files
|
|
168
|
+
*.tmp
|
|
169
|
+
*.bak
|
|
170
|
+
*.swp
|
|
171
|
+
*~
|
|
172
|
+
CLAUDE.md
|
|
173
|
+
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
# Pre-commit hooks for CodeOptiX
|
|
2
|
+
# See https://pre-commit.com for more information
|
|
3
|
+
# Install: pre-commit install
|
|
4
|
+
# Run: pre-commit run --all-files
|
|
5
|
+
|
|
6
|
+
repos:
|
|
7
|
+
# General file checks
|
|
8
|
+
- repo: https://github.com/pre-commit/pre-commit-hooks
|
|
9
|
+
rev: v5.0.0
|
|
10
|
+
hooks:
|
|
11
|
+
- id: trailing-whitespace
|
|
12
|
+
- id: end-of-file-fixer
|
|
13
|
+
- id: check-yaml
|
|
14
|
+
- id: check-toml
|
|
15
|
+
- id: check-json
|
|
16
|
+
- id: check-added-large-files
|
|
17
|
+
args: ['--maxkb=1000']
|
|
18
|
+
- id: check-merge-conflict
|
|
19
|
+
- id: check-case-conflict
|
|
20
|
+
- id: detect-private-key
|
|
21
|
+
- id: mixed-line-ending
|
|
22
|
+
args: ['--fix=lf']
|
|
23
|
+
|
|
24
|
+
# Ruff: Fast Python linter and formatter
|
|
25
|
+
- repo: https://github.com/astral-sh/ruff-pre-commit
|
|
26
|
+
rev: v0.8.4
|
|
27
|
+
hooks:
|
|
28
|
+
# Run the linter
|
|
29
|
+
- id: ruff
|
|
30
|
+
args: [--fix, --exit-non-zero-on-fix]
|
|
31
|
+
exclude: ^src/codeoptix/vendor/
|
|
32
|
+
# Run the formatter
|
|
33
|
+
- id: ruff-format
|
|
34
|
+
exclude: ^src/codeoptix/vendor/
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
# Changelog
|
|
2
|
+
|
|
3
|
+
All notable changes to this project will be documented in this file.
|
|
4
|
+
|
|
5
|
+
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
|
|
6
|
+
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
|
|
7
|
+
|
|
8
|
+
## [Unreleased]
|
|
9
|
+
|
|
10
|
+
### Added
|
|
11
|
+
- Initial release of CodeOptiX
|
|
12
|
+
- GEPA optimization engine
|
|
13
|
+
- Bloom evaluation framework
|
|
14
|
+
- Built-in behaviors: insecure-code, vacuous-tests, plan-drift
|
|
15
|
+
- Support for multiple coding agents (Claude Code, Codex, Gemini CLI)
|
|
16
|
+
- Multi-provider LLM support (OpenAI, Anthropic, Google, Ollama)
|
|
17
|
+
- CI/CD integration
|
|
18
|
+
- Comprehensive documentation and examples
|
|
19
|
+
|
|
20
|
+
### Changed
|
|
21
|
+
|
|
22
|
+
### Deprecated
|
|
23
|
+
|
|
24
|
+
### Removed
|
|
25
|
+
|
|
26
|
+
### Fixed
|
|
27
|
+
|
|
28
|
+
### Security
|
|
29
|
+
|
|
30
|
+
## [0.1.0] - 2025-12-26
|
|
31
|
+
|
|
32
|
+
### Added
|
|
33
|
+
- Project initialization
|
|
@@ -0,0 +1,79 @@
|
|
|
1
|
+
# Code of Conduct
|
|
2
|
+
|
|
3
|
+
## Our Pledge
|
|
4
|
+
|
|
5
|
+
We as members, contributors, and leaders pledge to make participation in our community a harassment-free experience for everyone, regardless of age, body size, visible or invisible disability, ethnicity, sex characteristics, gender identity and expression, level of experience, education, socio-economic status, nationality, personal appearance, race, religion, or sexual identity and orientation.
|
|
6
|
+
|
|
7
|
+
We pledge to act and interact in ways that contribute to an open, welcoming, diverse, inclusive, and healthy community.
|
|
8
|
+
|
|
9
|
+
## Our Standards
|
|
10
|
+
|
|
11
|
+
Examples of behavior that contributes to a positive environment for our community include:
|
|
12
|
+
|
|
13
|
+
- Demonstrating empathy and kindness toward other people
|
|
14
|
+
- Being respectful of differing opinions, viewpoints, and experiences
|
|
15
|
+
- Giving and gracefully accepting constructive feedback
|
|
16
|
+
- Accepting responsibility and apologizing to those affected by our mistakes, and learning from the experience
|
|
17
|
+
- Focusing on what is best not just for us as individuals, but for the overall community
|
|
18
|
+
|
|
19
|
+
Examples of unacceptable behavior include:
|
|
20
|
+
|
|
21
|
+
- The use of sexualized language or imagery, and sexual attention or advances of any kind
|
|
22
|
+
- Trolling, insulting or derogatory comments, and personal or political attacks
|
|
23
|
+
- Public or private harassment
|
|
24
|
+
- Publishing others' private information, such as a physical or email address, without their explicit permission
|
|
25
|
+
- Other conduct which could reasonably be considered inappropriate in a professional setting
|
|
26
|
+
|
|
27
|
+
## Enforcement Responsibilities
|
|
28
|
+
|
|
29
|
+
Community leaders are responsible for clarifying and enforcing our standards of acceptable behavior and will take appropriate and fair corrective action in response to any behavior that they deem inappropriate, threatening, offensive, or harmful.
|
|
30
|
+
|
|
31
|
+
Community leaders have the right and responsibility to remove, edit, or reject comments, commits, code, wiki edits, issues, and other contributions that are not aligned to this Code of Conduct, and will communicate reasons for moderation decisions when appropriate.
|
|
32
|
+
|
|
33
|
+
## Scope
|
|
34
|
+
|
|
35
|
+
This Code of Conduct applies within all community spaces, and also applies when an individual is officially representing the community in public spaces. Examples of representing our community include using an official e-mail address, posting via an official social media account, or acting as an appointed representative at an online or offline event.
|
|
36
|
+
|
|
37
|
+
## Enforcement
|
|
38
|
+
|
|
39
|
+
Instances of abusive, harassing, or otherwise unacceptable behavior may be reported to the community leaders responsible for enforcement at [INSERT CONTACT METHOD]. All complaints will be reviewed and investigated promptly and fairly.
|
|
40
|
+
|
|
41
|
+
All community leaders are obligated to respect the privacy and security of the reporter of any incident.
|
|
42
|
+
|
|
43
|
+
## Enforcement Guidelines
|
|
44
|
+
|
|
45
|
+
Community leaders will follow these Community Impact Guidelines in determining the consequences for any action they deem in violation of this Code of Conduct:
|
|
46
|
+
|
|
47
|
+
### 1. Correction
|
|
48
|
+
|
|
49
|
+
**Community Impact**: Use of inappropriate language or other behavior deemed unprofessional or unwelcome in the community.
|
|
50
|
+
|
|
51
|
+
**Consequence**: A private, written warning from community leaders, providing clarity around the nature of the violation and an explanation of why the behavior was inappropriate. A public apology may be requested.
|
|
52
|
+
|
|
53
|
+
### 2. Warning
|
|
54
|
+
|
|
55
|
+
**Community Impact**: A violation through a single incident or series of actions.
|
|
56
|
+
|
|
57
|
+
**Consequence**: A warning with consequences for continued behavior. No interaction with the people involved, including unsolicited interaction with those enforcing the Code of Conduct, for a specified period of time. This includes avoiding interactions in community spaces as well as external channels like social media. Violating these terms may lead to a temporary or permanent ban.
|
|
58
|
+
|
|
59
|
+
### 3. Temporary Ban
|
|
60
|
+
|
|
61
|
+
**Community Impact**: A serious violation of community standards, including sustained inappropriate behavior.
|
|
62
|
+
|
|
63
|
+
**Consequence**: A temporary ban from any sort of interaction or public communication with the community for a specified period of time. No public or private interaction with the people involved, including unsolicited interaction with those enforcing the Code of Conduct, is allowed during this period. Violating these terms may lead to a permanent ban.
|
|
64
|
+
|
|
65
|
+
### 4. Permanent Ban
|
|
66
|
+
|
|
67
|
+
**Community Impact**: Demonstrating a pattern of violation of community standards, including sustained inappropriate behavior, harassment of an individual, or aggression toward or disparagement of classes of individuals.
|
|
68
|
+
|
|
69
|
+
**Consequence**: A permanent ban from any sort of public interaction within the community.
|
|
70
|
+
|
|
71
|
+
## Attribution
|
|
72
|
+
|
|
73
|
+
This Code of Conduct is adapted from the [Contributor Covenant][homepage], version 2.0, available at https://www.contributor-covenant.org/version/2/0/code_of_conduct.html.
|
|
74
|
+
|
|
75
|
+
Community Impact Guidelines were inspired by [Mozilla's code of conduct enforcement ladder](https://github.com/mozilla/diversity).
|
|
76
|
+
|
|
77
|
+
[homepage]: https://www.contributor-covenant.org
|
|
78
|
+
|
|
79
|
+
For answers to common questions about this code of conduct, see the FAQ at https://www.contributor-covenant.org/faq. Translations are available at https://www.contributor-covenant.org/translations.
|
|
@@ -0,0 +1,118 @@
|
|
|
1
|
+
# Contributing to CodeOptiX
|
|
2
|
+
|
|
3
|
+
Thank you for your interest in contributing to CodeOptiX! This document provides guidelines and instructions for contributing.
|
|
4
|
+
|
|
5
|
+
## Development Setup
|
|
6
|
+
|
|
7
|
+
### Prerequisites
|
|
8
|
+
|
|
9
|
+
- Python 3.12+
|
|
10
|
+
- [uv](https://github.com/astral-sh/uv) (recommended) or pip
|
|
11
|
+
|
|
12
|
+
### Installation
|
|
13
|
+
|
|
14
|
+
```bash
|
|
15
|
+
# Clone the repository
|
|
16
|
+
git clone https://github.com/SuperagenticAI/codeoptix.git
|
|
17
|
+
cd codeoptix
|
|
18
|
+
|
|
19
|
+
# Install with uv (recommended)
|
|
20
|
+
uv sync --dev --extra docs
|
|
21
|
+
|
|
22
|
+
# Or with pip
|
|
23
|
+
pip install -e ".[dev,docs]"
|
|
24
|
+
|
|
25
|
+
# Install pre-commit hooks
|
|
26
|
+
uv run pre-commit install
|
|
27
|
+
```
|
|
28
|
+
|
|
29
|
+
## Development Workflow
|
|
30
|
+
|
|
31
|
+
### Running Tests
|
|
32
|
+
|
|
33
|
+
```bash
|
|
34
|
+
# Run all tests
|
|
35
|
+
uv run pytest
|
|
36
|
+
|
|
37
|
+
# Run with coverage
|
|
38
|
+
uv run pytest --cov=codeoptix --cov-report=html
|
|
39
|
+
|
|
40
|
+
# Run specific test file
|
|
41
|
+
uv run pytest tests/test_evaluation.py -v
|
|
42
|
+
```
|
|
43
|
+
|
|
44
|
+
### Code Quality
|
|
45
|
+
|
|
46
|
+
We use [Ruff](https://github.com/astral-sh/ruff) for linting and formatting:
|
|
47
|
+
|
|
48
|
+
```bash
|
|
49
|
+
# Format code
|
|
50
|
+
uv run ruff format .
|
|
51
|
+
|
|
52
|
+
# Lint code
|
|
53
|
+
uv run ruff check .
|
|
54
|
+
|
|
55
|
+
# Fix auto-fixable issues
|
|
56
|
+
uv run ruff check . --fix
|
|
57
|
+
```
|
|
58
|
+
|
|
59
|
+
### Pre-commit Hooks
|
|
60
|
+
|
|
61
|
+
Pre-commit hooks run automatically on commit. To run manually:
|
|
62
|
+
|
|
63
|
+
```bash
|
|
64
|
+
uv run pre-commit run --all-files
|
|
65
|
+
```
|
|
66
|
+
|
|
67
|
+
## Pull Request Process
|
|
68
|
+
|
|
69
|
+
1. **Fork** the repository
|
|
70
|
+
2. **Create a branch** for your feature or fix:
|
|
71
|
+
```bash
|
|
72
|
+
git checkout -b feature/your-feature-name
|
|
73
|
+
```
|
|
74
|
+
3. **Make your changes** and ensure:
|
|
75
|
+
- Tests pass (`uv run pytest`)
|
|
76
|
+
- Code is formatted (`uv run ruff format .`)
|
|
77
|
+
- Linting passes (`uv run ruff check .`)
|
|
78
|
+
4. **Commit** your changes with a descriptive message
|
|
79
|
+
5. **Push** to your fork
|
|
80
|
+
6. **Open a Pull Request** against `main`
|
|
81
|
+
|
|
82
|
+
### Commit Messages
|
|
83
|
+
|
|
84
|
+
- Use clear, descriptive commit messages
|
|
85
|
+
- Start with a verb (Add, Fix, Update, Remove, etc.)
|
|
86
|
+
- Keep the first line under 72 characters
|
|
87
|
+
|
|
88
|
+
Examples:
|
|
89
|
+
- `Add support for custom behaviors`
|
|
90
|
+
- `Fix evaluation engine timeout handling`
|
|
91
|
+
- `Update documentation for CLI usage`
|
|
92
|
+
|
|
93
|
+
## Code Style
|
|
94
|
+
|
|
95
|
+
- Follow [PEP 8](https://peps.python.org/pep-0008/) style guide
|
|
96
|
+
- Use type hints for function signatures
|
|
97
|
+
- Write docstrings for public functions and classes (Google style)
|
|
98
|
+
- Keep functions focused and small
|
|
99
|
+
|
|
100
|
+
## Testing
|
|
101
|
+
|
|
102
|
+
- Write tests for new features
|
|
103
|
+
- Maintain or improve test coverage
|
|
104
|
+
- Use pytest fixtures for common test setup
|
|
105
|
+
- Test files should be in `tests/` directory
|
|
106
|
+
|
|
107
|
+
## Documentation
|
|
108
|
+
|
|
109
|
+
- Update documentation for user-facing changes
|
|
110
|
+
- Documentation is in `docs/` using MkDocs
|
|
111
|
+
- Preview docs locally: `uv run mkdocs serve`
|
|
112
|
+
|
|
113
|
+
## Questions?
|
|
114
|
+
|
|
115
|
+
- Open a [GitHub Discussion](https://github.com/SuperagenticAI/codeoptix/discussions)
|
|
116
|
+
- Check existing [Issues](https://github.com/SuperagenticAI/codeoptix/issues)
|
|
117
|
+
|
|
118
|
+
Thank you for contributing!
|