[DRAFT] [scielo-tools-18]: Adiciona API REST para marcar o front SPS 1.10 - #35
Draft
gitnnolabs wants to merge 4 commits into
Draft
[DRAFT] [scielo-tools-18]: Adiciona API REST para marcar o front SPS 1.10#35gitnnolabs wants to merge 4 commits into
gitnnolabs wants to merge 4 commits into
Conversation
Corta prefill no Ollama ao fundir journals e skips redundantes e adicionar legal-doc com collab, sem alterar o system prompt. Co-authored-by: Cursor <cursoragent@cursor.com>
Deixa de enviar JSON Schema no Ollama (descodificação constrangida lenta no 8B) e mantém o modelo residente com keep_alive=-1. Co-authored-by: Cursor <cursoragent@cursor.com>
Novo app front, independente, com POST /api/v1/front/ e /docx/, cache por checksum e XML <front> só com tags SciELO PS.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
O que esse PR faz?
Cria o app
frontcom endpoints autenticados para marcar o front do artigo a partir de texto ou DOCX. A LLM local extrai metadados; a API devolve JSON ou o elemento<front>SPS 1.10 completo (journal-meta+article-meta), emitindo apenas tags oficiais presentes no texto. Resultados são persistidos por checksum para não reenviar o mesmo texto à LLM.Onde a revisão poderia começar?
front/api/v1/views.pyefront/data_utils.py(get_front_xml).Como este poderia ser testado manualmente?
pytest --reuse-db front/tests -qFRONT_URL(Ollama) eFRONT_ENABLED=true.POST /api/v1/auth/token/.POST /api/v1/front/com{"front": "...", "type": "xml", "language": "pt"}e confirmardatacomeçando por<front.front(400) e sem token (401/403).Algum cenário de contexto que queira dar?
O XML segue o tagset SciELO PS 1.10: não se inventam tags;
article-titleeabstractnão levam@xml:lang; ORCID é obrigatório no SPS para pelo menos um autor quando o texto o trouxer.journal-metasó entra se o texto tiver dados de periódico.Screenshots
N/A
Quais são tickets relevantes?
#33
Referências
<front>: https://scielo.readthedocs.io/projects/scielo-publishing-schema/pt-br/master/tagset/elemento-front.html