Commit graph

142 commits

Author SHA1 Message Date
Pier-Jean Malandrino
e4bbffe258 Redesign history list as cards with subtle completed badges
Replace flat rows with rounded cards matching documents page style.
Reduce COMPLETED badge to a green dot so exceptions (FAILED, RUNNING)
stand out visually instead of blending into a wall of green badges.
2026-04-02 16:41:06 +02:00
Pier-Jean Malandrino
a78c9ec415 Redesign documents page rows as cards with accent hover
Replace flat border-bottom rows with rounded cards that have a subtle
border and accent-colored border on hover for better visual hierarchy.
2026-04-02 16:40:20 +02:00
Pier-Jean Malandrino
126c41a033 Fix studio topbar title wrapping when sidebar is open
Prevent multi-line title by adding ellipsis truncation and min-width
constraints on the topbar-left container.
2026-04-02 16:39:08 +02:00
Pier-Jean Malandrino
c60407f7a2
Merge pull request #35 from scub-france/feature/studio-tabs-redesign
Redesign studio mode tabs with icons and accent highlight
2026-04-02 16:28:19 +02:00
Pier-Jean Malandrino
4b0bb55cfe Redesign studio mode tabs with icons and accent highlight
Add contextual icons (gear, checkmark, grid) to Configure, Verify,
and Prepare tabs. Replace flat white/shadow active state with accent
color background for clearer visual feedback. Use inner padding and
individual border-radius for a modern segmented control look.
2026-04-02 16:27:02 +02:00
Pier-Jean Malandrino
4df91b41d5
Merge pull request #34 from scub-france/fix/harmonize-bbox-highlight
Dim non-highlighted bboxes in Verify mode for visual consistency
2026-04-02 16:21:12 +02:00
Pier-Jean Malandrino
1ed9552224 Dim non-highlighted bboxes in Verify mode for visual consistency
Apply the same dimming strategy used in Prepare mode: when an element
is highlighted, reduce stroke and fill opacity of all other bboxes
so the focused element stands out clearly.
2026-04-02 16:19:43 +02:00
Pier-Jean Malandrino
1ff8c5108f Add release process, dynamic versioning, and changelog catch-up
Replace hardcoded version strings with build-time injection:
- Frontend: Vite __APP_VERSION__ from env or package.json
- Backend: APP_VERSION env var exposed via /health endpoint
- Docker: build arg propagated through both stages
- CI: release workflow extracts version from git tag

Document branching strategy and release process in CONTRIBUTING.md.
Catch up CHANGELOG with v0.2.0 and Unreleased sections.
Sync package.json version to 0.3.0.
2026-04-02 16:08:37 +02:00
Pier-Jean Malandrino
84645f0d70
Merge pull request #33 from scub-france/feature/include-chunking
Feature/include chunking
2026-04-02 15:21:15 +02:00
Pier-Jean Malandrino
82059ec0b1 Add tests for ChunkBbox domain, schema, and API serialization
Cover ChunkBbox construction and serialization, ChunkBboxResponse
camelCase output, rechunk endpoint bbox propagation, and frontend
store test data alignment with the new bboxes field.
2026-04-02 14:47:40 +02:00
Pier-Jean Malandrino
4af6b5b231 Add chunk-to-bbox hover highlighting in Prepare mode
Extract bounding boxes from chunk doc_items provenance in the chunker,
propagate through domain/service/API layers, and render highlighted
bboxes on canvas when hovering a chunk card. Reset highlights on
mode and page changes to prevent stale visual state.
2026-04-02 14:47:31 +02:00
Pier-Jean Malandrino
ace37429bd Improve Prepare mode with page filtering, collapsible config, and bbox overlay
Filter chunks by current PDF page for consistency with Verify mode.
Add collapsible chunking config section and paginated chunk list.
Show BboxOverlay in Prepare mode so users see element bounding boxes.
Fix scroll containment on prepare panel.
2026-04-02 13:41:59 +02:00
Pier-Jean Malandrino
102a11765a Add reusable pagination composable and PaginationBar component
Generic usePagination composable with page navigation, size control,
and auto-reset on data change. PaginationBar renders prev/next with
page size selector. Both support i18n.
2026-04-02 13:41:50 +02:00
Pier-Jean Malandrino
13ac8a11f0 Fix feature flag health check blocked by CORS
Use relative /health path through Vite proxy instead of absolute URL
to localhost:8000, matching the pattern used by all other API calls.
2026-04-02 12:44:08 +02:00
Pier-Jean Malandrino
e74c788ad4
Merge pull request #32 from scub-france/feature/include-chunking
Feature/include chunking
2026-04-02 12:38:08 +02:00
Pier-Jean Malandrino
ebdf9ae1be Add frontend chunking feature with Prepare mode
Chunk/ChunkingOptions types, rechunkAnalysis API, store actions
(currentChunks, rechunk), ChunkPanel UI, Prepare tab in StudioPage
gated by chunking feature flag, i18n keys (FR/EN), and tests.
2026-04-02 12:33:07 +02:00
Pier-Jean Malandrino
05de0cc774 Add chunking tests and update existing test assertions
16 new chunking tests (domain, schemas, API endpoints).
Update existing tests for chunkingOptions parameter and document_json mock.
2026-04-02 12:33:07 +02:00
Pier-Jean Malandrino
a9517d38eb Add chunking service orchestration, API endpoints, and wiring
AnalysisService gains rechunk() and inline chunking during conversion.
ChunkingOptionsRequest/ChunkResponse schemas, POST rechunk endpoint,
and conditional chunker injection in main.py (local engine only).
2026-04-02 12:33:07 +02:00
Pier-Jean Malandrino
4b1ec364f4 Add LocalChunker adapter and DoclingDocument serialization
LocalChunker implements DocumentChunker port using docling-core chunkers.
LocalConverter now serializes DoclingDocument to JSON for re-chunking support.
2026-04-02 12:33:07 +02:00
Pier-Jean Malandrino
f5b31f809f Add document_json and chunks_json persistence layer
Schema migration for new columns, repository read/write support,
and dedicated update_chunks method for re-chunking operations.
2026-04-02 12:33:07 +02:00
Pier-Jean Malandrino
78c27b087d Add chunking domain objects and DocumentChunker port
ChunkingOptions and ChunkResult value objects, document_json/chunks_json
fields on AnalysisJob, and DocumentChunker protocol for adapter injection.
2026-04-02 12:33:07 +02:00
Pier-Jean Malandrino
d42c97160d Format backend codebase with ruff 2026-04-02 12:33:07 +02:00
Pier-Jean Malandrino
29d36b9fc2
Merge pull request #31 from scub-france/feature/feature-flipping
Add feature flipping mechanism
2026-04-02 11:29:57 +02:00
Pier-Jean Malandrino
2e086cc4f3 Add feature flipping mechanism
Introduce a feature-flags module in the frontend that detects
the backend conversion engine via /health and exposes typed
feature flags. Chunking is enabled only in local engine mode.
2026-04-02 11:25:23 +02:00
Pier-Jean Malandrino
0e302c30ea
Merge pull request #30 from scub-france/fix/move-vitest-mocker-to-devdeps
Fix/move vitest mocker to devdeps
2026-04-02 10:56:16 +02:00
Pier-Jean Malandrino
8319b45f25 Add excalidraw folder to gitignore 2026-04-02 10:55:25 +02:00
Pier-Jean Malandrino
c5afe5ad88 Add CLAUDE.md to gitignore
Local Claude Code configuration files should not be committed.
2026-04-01 14:55:53 +02:00
Pier-Jean Malandrino
b93cf43c2a Move @vitest/mocker from dependencies to devDependencies
Test utility was incorrectly listed as a production dependency,
adding unnecessary weight to the production Docker image.
2026-04-01 14:55:31 +02:00
Pier-Jean Malandrino
f190b39bec
Merge pull request #28 from scub-france/fix/zombie-jobs-and-json-parse
Add Docling - serve
2026-04-01 14:36:22 +02:00
Pier-Jean Malandrino
2b991108f7 Rebase sync 2026-03-31 16:55:17 +02:00
Pier-Jean Malandrino
1b8cfe0a6b Fix Serve API contract: send to_formats as repeated form fields
Docling Serve expects array fields (to_formats) as repeated multipart
keys (to_formats=md&to_formats=html&to_formats=json), not a JSON
string. Changed _build_form_data to return list[tuple] so httpx sends
repeated keys correctly. Fixes 422 Unprocessable Entity on convert.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-31 16:52:36 +02:00
Pier-Jean Malandrino
001cf6807c Fix audit findings: security, robustness, and dead code
- Remove dead get_analysis_service() function in main.py
- Scope file deletion to UPLOAD_DIR to prevent path traversal
- Parse datetime strings back to datetime objects in repos
- Add 10-minute polling timeout in frontend analysis store
- Accept .pdf extension (not just MIME type) on drag-and-drop
- Guard localStorage access for private browsing compatibility

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-31 16:52:36 +02:00
Pier-Jean Malandrino
6b0fc45e5d Fix upload error not displayed in DocumentUpload component
Wrap store.upload() calls in try-catch in both onFileSelect and onDrop
so thrown errors (e.g. file too large) don't bubble up unhandled.
Display store.error inline below the upload hint so users see why
their upload was rejected.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-31 16:52:36 +02:00
Pier-Jean Malandrino
0af3b81b8f Fix zombie jobs and unprotected JSON parse
Bug #1: _on_task_done now receives job_id via functools.partial and
calls _mark_failed when the background task raises or is cancelled,
preventing jobs from being stuck in RUNNING state forever.

Bug #5: _parse_response wraps json.loads in try/except JSONDecodeError
so malformed json_content strings fall back gracefully instead of crashing.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-31 16:52:36 +02:00
Pier-Jean Malandrino
a63af61b73 Fix lint ans test errors 2026-03-31 16:35:48 +02:00
Pier-Jean Malandrino
fe4e792885 Fix audit findings: remove domain→infra violation, align Serve API, fix DI
- Delete domain/parsing.py (broke hexagonal layering by importing infra)
- Migrate all tests to import directly from domain.value_objects and
  infra.local_converter
- Rewrite ServeConverter to match real Docling Serve v1 API contract:
  options sent as individual form fields (not JSON blob), response
  parsed from document.json_content (DoclingDocument), proper bbox
  coord_origin handling (TOPLEFT/BOTTOMLEFT)
- Transmit all conversion options including generate_picture_images
- Replace fragile lazy import circular dep with FastAPI Depends() +
  app.state for AnalysisService injection
- Add frontend file size validation (50MB) before upload

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-31 10:58:58 +02:00
Pier-Jean Malandrino
a3486a8501 Add ServeConverter adapter for remote Docling Serve integration
Implement the HTTP client adapter that delegates document conversion
to a remote Docling Serve instance via its /v1/convert/file endpoint.
Switchable via CONVERSION_ENGINE=remote env var. Includes health check,
API key auth, response parsing, and 30 new tests covering parsing,
type mapping, HTTP calls, and DI wiring.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-31 10:36:35 +02:00
Pier-Jean Malandrino
3743ed4ca8 Refactor backend to hexagonal architecture for converter extensibility
Extract domain value objects and ports from parsing.py, move Docling-specific
code to infra/local_converter.py, and convert analysis_service to a class
with injected DocumentConverter. This prepares the codebase for plugging in
alternative conversion backends (e.g. Docling Serve) via the Protocol pattern.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-31 10:34:07 +02:00
Pier-Jean Malandrino
31ccd076c9
Merge pull request #25 from scub-france/fix/security-dependabot
Fix/security dependabot
2026-03-29 21:12:37 +02:00
Pier-Jean Malandrino
c9de4bbd8a Fix esbuild vulnerability by upgrading Vite 5 → 6 and vitest
Update vite 5.4.21 → 6.4.1, @vitejs/plugin-vue and vitest to resolve
Dependabot alert #1 (esbuild dev server request forgery, now at 0.25.12)
2026-03-28 15:16:09 +01:00
Pier-Jean Malandrino
19125d4230 Fix picomatch vulnerability by updating typescript-eslint
Update typescript-eslint 8.57.1 → 8.57.2 to resolve Dependabot alert #3
(POSIX Character Classes method injection in picomatch, now at 4.0.4)
2026-03-28 15:15:01 +01:00
Pier-Jean Malandrino
c3e96b62cd
Merge pull request #24 from scub-france/bug-doc-upload
Fix evetn listening redirection on doc upload
2026-03-24 08:47:55 +01:00
Pier-Jean Malandrino
40cba0f036 Fix type in emit 2026-03-24 08:38:55 +01:00
Pier-Jean Malandrino
079595b57d Fix evetn listening redirection on doc upload 2026-03-23 10:59:52 +01:00
Pier-Jean Malandrino
d22f2e973e Add GIF in README 2026-03-23 10:55:54 +01:00
Pier-Jean Malandrino
f77579ea2c Add missing config for doc publication 2026-03-23 10:25:55 +01:00
Pier-Jean Malandrino
1edd0668d1 Fix Ruff errror, update node and fix buttton breakline 2026-03-23 10:13:24 +01:00
Pier-Jean Malandrino
f267f6c183 Just can't help myself with this.. 2026-03-23 10:04:39 +01:00
Pier-Jean Malandrino
41ee11f5c7
Merge pull request #22 from scub-france/live-documentaiton
Add live documentaiton and change architecture diagram
2026-03-23 09:51:57 +01:00
Pier-Jean Malandrino
c2aeec3092 Add live documentaiton and change architecture diagram 2026-03-23 09:51:03 +01:00