Skip to content

[codex] Harden document briefing cache distribution and grounding#1

Merged
dd3ok merged 25 commits into
mainfrom
codex/distribution-grounding-llm-hardening
May 14, 2026
Merged

[codex] Harden document briefing cache distribution and grounding#1
dd3ok merged 25 commits into
mainfrom
codex/distribution-grounding-llm-hardening

Conversation

@dd3ok
Copy link
Copy Markdown
Owner

@dd3ok dd3ok commented May 13, 2026

Summary

  • Package briefing templates as installed package resources and add wheel/sdist smoke coverage in CI.
  • Clarify unsupported URL input behavior, preserve normalization unknowns through cache/rendering, and tighten privacy guidance.
  • Strengthen evidence grounding with schema 1.1.0, structured claim evidence checks, and stricter cache/schema invalidation.
  • Harden the OpenAI structured summarizer path with token budgeting, chunk/merge support, retry/backoff/timeout controls, statusless timeout/connection retry handling, strict JSON schema cleanup, exact schema-version prompting, oversized-section splitting, and returned schema-version enforcement.
  • Add the implementation plan under docs/superpowers/plans/ and refresh validation notes.

Validation

  • TMPDIR=/tmp PYTEST_DISABLE_PLUGIN_AUTOLOAD=1 PYTHONDONTWRITEBYTECODE=1 PYTHONPATH=src python3 -m pytest -q -> 110 passed, 1 skipped
  • PYTHONDONTWRITEBYTECODE=1 PYTHONPATH=src python3 scripts/validate_skill.py --run-evals -> OK, 19 test files, 6 eval cases, 9 trigger cases, 4 model benchmark cases
  • TMPDIR=/tmp PYTEST_DISABLE_PLUGIN_AUTOLOAD=1 PYTHONDONTWRITEBYTECODE=1 PYTHONPATH=src python3 -m pytest tests/test_distribution_smoke.py -q -> 1 skipped unless artifact smoke is explicitly enabled
  • GitHub CI run 25839910412 -> success, including Python 3.10/3.11/3.12 tests and wheel/sdist distribution smoke
  • python3 -m build --version -> unavailable locally: No module named build; CI installs build for distribution smoke

Copy link
Copy Markdown

@gemini-code-assist gemini-code-assist Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request hardens the distribution and LLM integration of the document-briefing-cache skill by migrating templates to package resources, upgrading the document summary schema to version 1.1.0 to mandate evidence for all claims, and enhancing the OpenAI summarizer with chunking, retries, and production-oriented configuration flags. Documentation was also updated to clarify input boundaries and privacy guidance. Review feedback suggests improving the OpenAI retry logic with exponential backoff, expanding transient error detection to include SDK-specific connection and timeout exceptions, and ensuring the rule-based summarizer provides evidence when falling back to document titles.

Comment thread src/document_briefing_cache/summarizers.py
Comment thread src/document_briefing_cache/summarizers.py Outdated
Comment thread src/document_briefing_cache/summarizers.py
Comment thread src/document_briefing_cache/summarizers.py Outdated
@dd3ok dd3ok marked this pull request as ready for review May 14, 2026 03:12
Copy link
Copy Markdown

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 9685e685ab

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread src/document_briefing_cache/summarizers.py
Comment thread src/document_briefing_cache/llm.py Outdated
@dd3ok dd3ok merged commit 49df9b5 into main May 14, 2026
8 checks passed
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