Skip to content

feat(server): POST /extract, POST /import, GET /export endpoints - #610

Merged
ajianaz merged 4 commits into
developfrom
feat/server-extract-import-export
Jul 7, 2026
Merged

ajianaz merged 4 commits into
developfrom
feat/server-extract-import-export

Conversation

@ajianaz

@ajianaz ajianaz commented Jul 7, 2026

Copy link
Copy Markdown
Collaborator

Summary

Move Extractor from uteke-cli to uteke-core (shared module), then add three new HTTP endpoints to uteke-serve:

Endpoint Method Description
/extract POST LLM fact extraction + auto-store (1MB limit)
/import JSONL import with re-embedding (5MB limit)
/export GET JSONL export (optional ?namespace= filter)

Changes

  • uteke-core: New extraction.rs module (Extractor moved from uteke-cli)
  • uteke-server: New handlers + types for extract/import/export
  • uteke-cli: Extract command now delegates to uteke-core Extractor (dedup)

Details

  • Extraction reads [extraction] config from uteke.toml
  • API key never accepted from request body (config/env only)
  • Write token required for all three endpoints
  • Net -213 lines (more deleted than added) thanks to Extractor dedup

Closes #604, #605, #606

…#605 #606)

Move Extractor from uteke-cli to uteke-core for server reuse.
Add three new HTTP endpoints to uteke-serve:

- POST /extract: LLM fact extraction + auto-store (1MB limit)
- POST /import: JSONL import with re-embedding (5MB limit)
- GET /export: JSONL export (optional ?namespace= filter)

Extraction reads [extraction] config from uteke.toml.
API key never accepted from request body (config/env only).
Write token required for all three endpoints.

Closes #604, #605, #606
@github-actions

github-actions Bot commented Jul 7, 2026

Copy link
Copy Markdown

🔍 Cora AI Code Review

✅ No issues found. Code looks good!


Review powered by cora-cli · BYOK · MIT

ajianaz added 3 commits July 7, 2026 20:09
…onfig.model is String

CI caught E0308: if/else arms had incompatible types.
Explicit annotate as String and use .to_owned() for the &str branch.
E0433 in /export handler — Header::from_bytes used without import.
- handlers.rs: if let Err(_) → .is_err() (2x redundant pattern matching)
- handlers.rs: &ctx → ctx (needless borrow)
- types.rs: #[allow(dead_code)] on ImportRequest.tags (not yet wired)
- extract.rs: #[allow(unused_imports)] on re-exports module
@ajianaz
ajianaz merged commit 7c11df9 into develop Jul 7, 2026
8 checks passed
@ajianaz
ajianaz deleted the feat/server-extract-import-export branch July 7, 2026 13:29
ajianaz added a commit that referenced this pull request Aug 13, 2026
…xport

feat(server): POST /extract, POST /import, GET /export endpoints
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.

Feature parity: POST /extract (and other CLI-only → HTTP endpoints)

1 participant