stats/status : libellés pivotés — sites du Groupe KA (tagline, KPI, tableaux, records, textes des pages)
5 changed files +18 −16
modified
apps/api/stats.py
+10 −10
@@ -36,7 +36,7 @@ SITE = { | ||
| 36 | 36 | "wordmark": "Trouve·Ka", |
| 37 | 37 | "domain": "www.trouve-ka.com", |
| 38 | 38 | "accent": "#1c7ed6", |
| 39 | − "tagline": "Le moteur de recherche du web québécois", | |
| 39 | + "tagline": "Le moteur de recherche du Groupe KA", | |
| 40 | 40 | } |
| 41 | 41 | |
| 42 | 42 | PERIOD_LABELS = { |
@@ -54,7 +54,7 @@ OUTCOME_LABELS = { | ||
| 54 | 54 | "indexed": "Indexée", |
| 55 | 55 | "duplicate": "Doublon", |
| 56 | 56 | "error": "Erreur", |
| 57 | − "not_quebec": "Hors Québec", | |
| 57 | + "not_quebec": "Hors périmètre", | |
| 58 | 58 | "robots_blocked": "Bloquée (robots.txt)", |
| 59 | 59 | "redirect": "Redirection", |
| 60 | 60 | "unchanged": "Inchangée", |
@@ -493,7 +493,7 @@ async def _build(db, period: str, from_s: str | None, to_s: str | None) -> dict: | ||
| 493 | 493 | kpis = [ |
| 494 | 494 | {"id": "pages", "label": "Pages indexées (total)", "value": docs_total, |
| 495 | 495 | "delta_pct": growth, "direction": "up", "spark": _spark(cum_points)}, |
| 496 | − {"id": "domaines", "label": "Domaines dans l'index", "value": cur["domains_count"]}, | |
| 496 | + {"id": "domaines", "label": "Sites du Groupe KA", "value": cur["domains_count"]}, | |
| 497 | 497 | {"id": "crawlees", "label": f"Pages crawlées — {label}", "value": attempts_cur, |
| 498 | 498 | "delta_pct": _delta(attempts_cur, attempts_prev), "spark": _spark(crawl_pts)}, |
| 499 | 499 | {"id": "rythme", "label": "Rythme de crawl", "value": round(attempts_cur / hours, 1), |
@@ -583,8 +583,8 @@ async def _build(db, period: str, from_s: str | None, to_s: str | None) -> dict: | ||
| 583 | 583 | for o, n in sorted(outcome_totals.items(), key=lambda kv: -kv[1])]}, |
| 584 | 584 | {"id": "http", "title": f"Crawl par classe de statut HTTP — {label}", "kind": "bars", |
| 585 | 585 | "items": [{"label": c, "value": st_totals[c]} for c in st_keys]}, |
| 586 | − {"id": "topdom", "title": "Top domaines par pages indexées (tout l'index)", "kind": "bars", | |
| 587 | − "items": [{"label": r["domain"], "value": r["page_count"]} for r in top_domains[:12]]}, | |
| 586 | + {"id": "topdom", "title": "Pages indexées par site du Groupe KA (tout l'index)", "kind": "bars", | |
| 587 | + "items": [{"label": r["domain"], "value": r["page_count"]} for r in top_domains[:14]]}, | |
| 588 | 588 | {"id": "frontier", "title": "File frontier par statut", "kind": "donut", |
| 589 | 589 | "items": [{"label": FRONTIER_LABELS.get(r["status"], r["status"]), "value": r["n"]} |
| 590 | 590 | for r in frontier]}, |
@@ -658,9 +658,9 @@ async def _build(db, period: str, from_s: str | None, to_s: str | None) -> dict: | ||
| 658 | 658 | |
| 659 | 659 | # ---- Tableaux ----------------------------------------------------------- |
| 660 | 660 | tables = [ |
| 661 | − {"id": "topdom", "title": "Top domaines (tout l'index)", | |
| 662 | − "columns": ["Domaine", "Pages indexées", "URLs connues", "Score Québec", "Dernier crawl"], | |
| 663 | − "rows": [[r["domain"], r["page_count"], r["url_count"], r["qs"], | |
| 661 | + {"id": "topdom", "title": "Sites du Groupe KA (tout l'index)", | |
| 662 | + "columns": ["Site", "Pages indexées", "URLs connues", "Dernier crawl"], | |
| 663 | + "rows": [[r["domain"], r["page_count"], r["url_count"], | |
| 664 | 664 | r["last_crawled_at"].astimezone(TZ).strftime("%Y-%m-%d %H:%M") |
| 665 | 665 | if r["last_crawled_at"] else "—"] for r in top_domains]}, |
| 666 | 666 | ] |
@@ -761,10 +761,10 @@ async def _build(db, period: str, from_s: str | None, to_s: str | None) -> dict: | ||
| 761 | 761 | "value": f"{_fr_int(hr_rec['n'])} pages", |
| 762 | 762 | "date": hr_rec["hour"].strftime("%Y-%m-%d %Hh")}) |
| 763 | 763 | if top_domains: |
| 764 | − records.append({"label": "Domaine le plus fourni", | |
| 764 | + records.append({"label": "Site le plus fourni", | |
| 765 | 765 | "value": f"{top_domains[0]['domain']} — {_fr_int(top_domains[0]['page_count'])} pages"}) |
| 766 | 766 | if deepest: |
| 767 | − records.append({"label": "Domaine exploré le plus profondément", | |
| 767 | + records.append({"label": "Site exploré le plus profondément", | |
| 768 | 768 | "value": f"{deepest['domain']} (profondeur {deepest['depth']})"}) |
| 769 | 769 | if bytes_max: |
| 770 | 770 | bm_val, bm_unit = _mb(bytes_max) |
modified
apps/web/app/stats/page.tsx
+1 −1
@@ -10,7 +10,7 @@ import { StatsPanel } from "./stats-panel"; | ||
| 10 | 10 | export const metadata: Metadata = { |
| 11 | 11 | title: "Statistiques", |
| 12 | 12 | description: |
| 13 | − "Tableau de bord analytique de Trouve-KA : pages et domaines indexés, rythme de crawl, erreurs, file frontier, tendances de recherche — et rapport PDF Groupe-KA.", | |
| 13 | + "Tableau de bord analytique de Trouve-KA, le moteur de recherche du Groupe KA : pages indexées par site de l'écosystème, rythme de crawl, erreurs, file frontier, tendances de recherche — et rapport PDF Groupe-KA.", | |
| 14 | 14 | }; |
| 15 | 15 | |
| 16 | 16 | export default function StatsPage() { |
modified
apps/web/app/stats/stats-panel.tsx
+2 −1
@@ -107,7 +107,8 @@ export function StatsPanel() { | ||
| 107 | 107 | Statistiques du moteur |
| 108 | 108 | </h1> |
| 109 | 109 | <p className="mt-2 max-w-xl text-sm text-ink-2"> |
| 110 | − Le tableau de bord complet de Trouve-KA : indexation, crawl, erreurs et | |
| 110 | + Le tableau de bord complet du moteur de recherche du Groupe KA : | |
| 111 | + indexation des sites de l'écosystème, crawl, erreurs et | |
| 111 | 112 | recherches — calculé sur les données réelles du moteur, rien d'inventé. |
| 112 | 113 | </p> |
| 113 | 114 | </div> |
modified
apps/web/app/status/page.tsx
+4 −3
@@ -10,7 +10,7 @@ import { StatusPanel } from "./status-panel"; | ||
| 10 | 10 | export const metadata: Metadata = { |
| 11 | 11 | title: "État du moteur", |
| 12 | 12 | description: |
| 13 | − "État en direct du moteur Trouve-KA : pages et domaines indexés, débit horaire, état du robot d'indexation.", | |
| 13 | + "État en direct du moteur de recherche du Groupe KA : pages indexées sur les sites de l'écosystème, débit horaire, état du robot d'indexation.", | |
| 14 | 14 | }; |
| 15 | 15 | |
| 16 | 16 | export default function StatusPage() { |
@@ -21,8 +21,9 @@ export default function StatusPage() { | ||
| 21 | 21 | État du moteur |
| 22 | 22 | </h1> |
| 23 | 23 | <p className="mt-2 text-sm text-ink-2"> |
| 24 | − Chiffres en direct, actualisés toutes les 10 secondes. La croissance | |
| 25 | − de l'index fait partie du produit. | |
| 24 | + Chiffres en direct, actualisés toutes les 10 secondes. Le moteur | |
| 25 | + indexe les sites du Groupe KA en continu — la croissance de | |
| 26 | + l'index fait partie du produit. | |
| 26 | 27 | </p> |
| 27 | 28 | <StatusPanel /> |
| 28 | 29 | </main> |
modified
apps/web/app/status/status-panel.tsx
+1 −1
@@ -134,7 +134,7 @@ export function StatusPanel() { | ||
| 134 | 134 | |
| 135 | 135 | <div className="mt-5 grid gap-4 sm:grid-cols-3"> |
| 136 | 136 | <Stat |
| 137 | − label="Domaines connus" | |
| 137 | + label="Sites du Groupe KA" | |
| 138 | 138 | value={formatNumber(status.domains_count)} |
| 139 | 139 | /> |
| 140 | 140 | <Stat |
| 141 | 141 | |