Skip to content

Add CI workflow and document it in the README#14

Merged
henry-hai merged 4 commits into
mainfrom
ci/github-actions
Jul 24, 2026
Merged

Add CI workflow and document it in the README#14
henry-hai merged 4 commits into
mainfrom
ci/github-actions

Conversation

@henry-hai

Copy link
Copy Markdown
Owner

Summary

Adds a GitHub Actions CI workflow and documents it in the README.

CI (Task 1)

  • .github/workflows/ci.yml runs on push and pull_request to main: Python 3.11, install requirements-dev.txt, ruff check ., then pytest tests/ -q.
  • ruff.toml pins a minimal correctness-focused rule set (pyflakes plus the import, statement, syntax, and warning subsets of pycodestyle). The one real finding, a missing final newline in six files, is fixed rather than silenced.
  • requirements-dev.txt adds ruff and pytest on top of the runtime requirements.
  • tests/ is an offline suite covering the schema contracts, source-label helpers, eval grading, and the Critic evidence wiring.
  • permissions is contents: read and the job needs no secrets.

What runs without keys, and what is gated

The whole suite passes with no OPENAI_API_KEY, PINECONE_API_KEY, or TAVILY_API_KEY set. Two things need live keys and are intentionally left out of CI:

  • the full evals/eval.py harness, which stands up the live agents, and
  • the Critic's groundedness judgment. The verdict is the model, so mocking it would only echo a canned answer back and prove nothing. That semantic check stays in eval.py for local runs with keys. CI instead verifies the deterministic logic around it, including that the Critic is handed the exact retrieved chunks as evidence and returns the verdict faithfully.

README (Task 2)

  • CI status badge under the title, owner and repo derived from the git remote.
  • Mermaid architecture diagram under the Architecture heading, verified against the code node by node before inserting.
  • One sentence noting the demo corpus (three public 10-K filings across retail, airline, and industrial sectors) and that the app is corpus-neutral.
  • Corrected one sentence: the eval harness verifies groundedness offline, not in CI, since that check needs live keys.

Verification

Clean Python 3.11.5 venv: install, ruff check . clean, and 22 tests pass in a few seconds, well under two minutes.

Run on push and pull_request to main: set up Python 3.11, install dev
requirements, run ruff, and run an offline pytest suite.

- ruff.toml pins a minimal correctness-focused rule set (pyflakes plus the
  import, statement, syntax, and warning subsets of pycodestyle) so linting
  flags real problems without rewriting deliberate style. Fixes the one real
  finding, a missing final newline in six files.
- requirements-dev.txt adds ruff and pytest on top of the runtime requirements.
- tests/ covers the schema contracts, source-label helpers, eval grading, and
  the Critic evidence wiring, all with no OpenAI, Pinecone, or Tavily key.
- The live eval harness and the Critic's groundedness judgment need real keys
  and are intentionally left out of CI.
- permissions is set to contents: read and the job needs no secrets.
- Add the CI workflow status badge under the title.
- Add a Mermaid architecture diagram of the Researcher and Critic graph plus the
  ingestion path under the Architecture heading.
- Note the demo corpus (three public 10-K filings across retail, airline, and
  industrial sectors) and that the app is corpus-neutral, in the Usage section.
- Correct one sentence: the eval harness verifies groundedness offline, not in
  CI, since that check needs live keys.
Importing config.py constructs the Pinecone client, which raises when no API
key is set, so test collection failed on a keyless runner. Set clearly-fake
placeholder keys in tests/conftest.py before the modules import, and only when
the environment does not already supply real ones. No test contacts a provider.
Document the GitHub Actions workflow in a new Continuous integration section
between Evaluation and Observability, and add a matching bullet to the Stack
list.
@henry-hai
henry-hai merged commit 6e5c288 into main Jul 24, 2026
1 check passed
@henry-hai
henry-hai deleted the ci/github-actions branch July 24, 2026 13:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant