feat: init Scalper — pipeline légal scrape+traduction (SCAL-1..SCAL-12)
- legal-source-check (liste de blocage scanlation, robots.txt, rate limiting) - sources: demo (fixture) + mangadex (API officielle) - cleaner, translator (LLM Mistral + glossaire), QA, exporter (md/json/html) - CLI + pipeline resumable (state.json), 22 tests unitaires - sous-agents Mistral Agents SDK: orchestrator + scraper/translator/qa - skills/ (6 SKILL.md), docs légales, CI GitHub Actions Refs: Jira SCAL-1 (Epic CDC), SCAL-2..SCAL-12 (backlog Scrum)
This commit is contained in:
commit
f38a1d630b
38 files changed
+1733
No files matched your search
@@ -0,0 +1,16 @@
|
||||
# Ajouter une source légale
|
||||
|
||||
1. **Vérification manuelle** : licence (API officielle / CC / domaine public / contenu propre),
|
||||
CGU (pas d'interdiction de scraping), `robots.txt` autorisant les chemins ciblés.
|
||||
2. **Enregistrement** : ajouter le domaine dans `TRUSTED_SOURCES` (`src/scalper/legal.py`)
|
||||
avec sa licence. Sans cet enregistrement, la source est **bloquée** par défaut.
|
||||
3. **Adaptateur** : implémenter le contrat `SourceAdapter` (`src/scalper/sources/base.py`) :
|
||||
- `list_series() -> list[Series]`
|
||||
- `list_chapters(series_id) -> list[ChapterRef]`
|
||||
- `fetch_chapter(chapter, dest_dir)` : écrit le brut dans `dest_dir` (raw.html + images + meta.json)
|
||||
puis l'enregistrer dans `get_adapter()` (`src/scalper/sources/__init__.py`).
|
||||
4. **Crawl respectueux** : passer par `RespectfulFetcher` (rate limiting ≥ 1 s, backoff, UA identifiable).
|
||||
5. **Tests** : ajouter un test hors ligne (fixtures mockées, aucun appel réseau en test).
|
||||
6. **PR** : ouvrir une PR liée au ticket Jira correspondant (projet SCAL).
|
||||
|
||||
Exemple d'adaptateur légal existant : `src/scalper/sources/mangadex.py` (API officielle).
|
||||
Reference in new issue
Block a user