Skip to content

feat: improve docs site UX and update model registry#2

Merged
johnnichev merged 1 commit intomainfrom
feat/docs-ux-and-model-updates
Mar 12, 2026
Merged

feat: improve docs site UX and update model registry#2
johnnichev merged 1 commit intomainfrom
feat/docs-ux-and-model-updates

Conversation

@johnnichev
Copy link
Copy Markdown
Owner

Summary

  • Docs site UX overhaul — Upgraded MkDocs Material theme with tab navigation (Core, Providers, RAG, Security, Reference), sticky header, footer nav, dark/light toggle, Inter + JetBrains Mono fonts, emoji icons, and code copy/annotate support
  • Landing page revamp — Feature cards grid, tabbed install instructions, admonition-based learning path, Material button links, and architecture diagram
  • Model registry updates — Fixed GPT-5.4 pricing ($5.00/$22.50 → $2.50/$15.00), fixed Gemini 3.1 Flash-Lite (model ID, pricing, max tokens), added Gemini Embedding 2 (total: 146 models)
  • Docs accuracy audit — Updated model count from 145 → 146 across 8 files, fixed stale pricing references

Test plan

  • All 1183 tests pass (pytest tests/ -x -q)
  • MkDocs builds successfully (mkdocs build)
  • All 27 HTML pages generated
  • Model count tests updated and passing
  • No broken links in docs (verified with mkdocs build)

Made with Cursor

- Upgrade MkDocs Material theme with tab navigation, sticky header,
  footer nav, custom purple/amber color scheme, Inter + JetBrains Mono
  fonts, emoji support, and code annotations
- Revamp docs landing page with feature cards grid, install tabs,
  admonition-based learning path, and Material button links
- Add custom CSS for card hover effects and dark mode tweaks
- Fix GPT-5.4 pricing ($5.00/$22.50 → $2.50/$15.00, was using >272K
  tier instead of standard pricing)
- Fix Gemini 3.1 Flash-Lite: correct model ID, pricing ($0.10/$0.40 →
  $0.25/$1.50), and max output tokens (8192 → 65536)
- Add Gemini Embedding 2 model (gemini-embedding-2-preview, $0.20/M)
- Update all docs from 145 → 146 model count across 8 files
- Reorganize mkdocs.yml nav into logical tab groups (Core, Providers,
  RAG, Security, Reference)
- Allow unsafe YAML tags in pre-commit for MkDocs emoji extensions

Made-with: Cursor
@johnnichev johnnichev merged commit 655d806 into main Mar 12, 2026
1 check passed
@johnnichev johnnichev deleted the feat/docs-ux-and-model-updates branch March 12, 2026 21:55
johnnichev added a commit that referenced this pull request Mar 24, 2026
Security:
- Path traversal in JsonFileSessionStore — validate session_id (#9)
- Unicode homoglyph bypass in injection screening — NFKD + zero-width
  strip + homoglyph map (#13)

Data integrity:
- FileKnowledgeStore._save_all() atomic write via tmp + os.replace (#10)
- JsonFileSessionStore.save() atomic write (#31)

Agent core:
- astream() uses self._effective_model (was self.config.model) (#1)
- Sync _check_policy rejects async confirm_action with clear error (#2)
- Sync _streaming_call isinstance(chunk, str) guard (#18)

Providers:
- FallbackProvider stream()/astream() record success after consumption,
  not before — circuit breaker now works for streaming (#3)
- Gemini response.text ValueError catch for tool-call-only responses (#4)

Tools:
- aexecute() uses run_in_executor(None) shared executor (#5)
- execute() awaits coroutines from async tools via asyncio.run (#6)

RAG:
- Hybrid search O(n²) → O(1) via text_to_key dict lookup (#7)
- SQLiteVectorStore thread safety + WAL mode (#8)

Evals:
- OutputEvaluator catches re.error on invalid regex (#11)
- JsonValidityEvaluator respects expect_json=False (#12)

16 new regression tests. Full suite: 2000 passed.
johnnichev added a commit that referenced this pull request Mar 24, 2026
- Bug #2: async confirm_action guard in sync _check_policy (was overwritten by Batch 2)
- Bug #8: SQLiteVectorStore WAL mode + threading.Lock (was overwritten by Batch 3)
- Bug #10: FileKnowledgeStore atomic write via tmp + os.replace (was overwritten by Batch 3)
- Fix SQLite test cleanup for WAL mode extra files
johnnichev added a commit that referenced this pull request Apr 3, 2026
1. LLM eval score injection: _extract_score now uses LAST match (not
   first) and strips fenced user content before extraction. Scores
   clamped to [0, 10] range. Prevents "Score: 10" injection via echoed
   user content in judge output.

2. ReDoS in PII guardrail: custom_patterns now validated with a smoke
   test (search against "a"*100) after compilation. Invalid patterns
   raise ValueError.

3. ReDoS in security screening: extra_patterns same treatment as #2.

4. Path traversal in ToolLoader.from_directory: symlink-following glob
   results now checked with is_relative_to() to prevent loading .py
   files outside the intended plugin directory.

All 3343 tests pass.
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