cof-cli 1.0.0__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- cof_cli/__init__.py +5 -0
- cof_cli/cli.py +305 -0
- cof_cli/completeness.py +131 -0
- cof_cli/container.py +230 -0
- cof_cli/convert.py +362 -0
- cof_cli/migrate.py +297 -0
- cof_cli/model.py +465 -0
- cof_cli/ops.py +381 -0
- cof_cli/schemas/attitude.schema.json +248 -0
- cof_cli/schemas/body.schema.json +98 -0
- cof_cli/schemas/card.schema.json +107 -0
- cof_cli/schemas/consent.schema.json +134 -0
- cof_cli/schemas/garments-1.0.json +41 -0
- cof_cli/schemas/hair.schema.json +104 -0
- cof_cli/schemas/manifest.schema.json +1757 -0
- cof_cli/schemas/pose.schema.json +206 -0
- cof_cli/schemas/psyche.schema.json +252 -0
- cof_cli/schemas/skeleton.schema.json +88 -0
- cof_cli/schemas/visemes.schema.json +28 -0
- cof_cli/schemas/voice-profile.schema.json +254 -0
- cof_cli/schemas/weights.schema.json +188 -0
- cof_cli/tokens.py +30 -0
- cof_cli/validate.py +985 -0
- cof_cli-1.0.0.dist-info/METADATA +39 -0
- cof_cli-1.0.0.dist-info/RECORD +28 -0
- cof_cli-1.0.0.dist-info/WHEEL +5 -0
- cof_cli-1.0.0.dist-info/entry_points.txt +2 -0
- cof_cli-1.0.0.dist-info/top_level.txt +1 -0
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
Metadata-Version: 2.4
|
|
2
|
+
Name: cof-cli
|
|
3
|
+
Version: 1.0.0
|
|
4
|
+
Summary: COF — Character Open File: validate, pack, unpack and convert .cof character containers
|
|
5
|
+
Author: Yann Souetre
|
|
6
|
+
License-Expression: MIT
|
|
7
|
+
Requires-Python: >=3.11
|
|
8
|
+
Description-Content-Type: text/markdown
|
|
9
|
+
Requires-Dist: jsonschema>=4.20
|
|
10
|
+
Provides-Extra: tokens
|
|
11
|
+
Requires-Dist: tiktoken>=0.7; extra == "tokens"
|
|
12
|
+
Provides-Extra: png
|
|
13
|
+
Requires-Dist: Pillow>=10; extra == "png"
|
|
14
|
+
Provides-Extra: dev
|
|
15
|
+
Requires-Dist: pytest>=8; extra == "dev"
|
|
16
|
+
Requires-Dist: Pillow>=10; extra == "dev"
|
|
17
|
+
|
|
18
|
+
# cof-cli
|
|
19
|
+
|
|
20
|
+
Outil de référence pour COF (Character Open File) : validation, empaquetage, conversions.
|
|
21
|
+
|
|
22
|
+
```bash
|
|
23
|
+
pip install -e ".[dev]" # depuis le dossier cli/
|
|
24
|
+
cof validate spec/examples/01-clara-text-only # dossier ou fichier .cof
|
|
25
|
+
cof pack spec/examples/01-clara-text-only -o clara.cof # recalcule hashes + complétude
|
|
26
|
+
cof info clara.cof
|
|
27
|
+
cof unpack clara.cof -o clara/
|
|
28
|
+
cof tokens clara.cof
|
|
29
|
+
cof import carte.png -o perso/ --age 30 --lang fr --keep-png # carte PNG CCv2/V3 → dossier COF
|
|
30
|
+
cof export clara.cof --format png -o clara.png # → PNG avec chunks chara + ccv3
|
|
31
|
+
cof export clara.cof --format soul -o ./agent/ # → SOUL.md + IDENTITY.md (OpenClaw)
|
|
32
|
+
cof export clara.cof --format card -o clara.card.json
|
|
33
|
+
cof export clara.cof --format soul --preset young -o ./agent/ # export depuis un autre preset
|
|
34
|
+
cof migrate dossier-v0.2/ # v0.2 → v0.3 (elements / presets)
|
|
35
|
+
```
|
|
36
|
+
|
|
37
|
+
Ce que `validate` vérifie (v0.3) : résolution des presets (slots, `extends`, `derives_from`), identifiants d'assets, dérivés hors des images de base, poids avec modèle de base, règles d'âge sur l'**âge le plus bas** (manifeste et `age_override`), styles mélangés dans un preset ; schéma du manifeste, sentinelle `mimetype`, chemins sûrs (pas de `..`, pas de symlink), absence de chiffrement, taux de compression, hashes SHA-256 et tailles des assets, cohérence âge ↔ corps, bloc intime interdit si mineur, consentement si personne réelle, transcriptions des échantillons de voix, contenu exécutable non déclaré, renvois `expresses` vers `psyche.json`, doublons textuels, budgets de tokens ; puis recalcule le KPI de complétude et les cibles prêtes.
|
|
38
|
+
|
|
39
|
+
Tests : `pytest` (dossier `cli/`). Tokens : installer `tiktoken` pour un comptage exact (sinon heuristique par caractères).
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
cof_cli/__init__.py,sha256=1ZUyfxfl6H5F6gBqsbpvPa83ohKzpjpM1m6OUB2otaw,158
|
|
2
|
+
cof_cli/cli.py,sha256=aprFSJhox1IA5pPzOnRyW1F6vuPtNWSeytMPZM8eMAM,16237
|
|
3
|
+
cof_cli/completeness.py,sha256=F2vAj_c1FLnzYOhfGBDXhCBiLmTxTrjzctzl5-0Up0o,6726
|
|
4
|
+
cof_cli/container.py,sha256=cMFXtKmQyySWHw1eXcNz6s3bV73gU90ppjs0Ea7ya6I,9490
|
|
5
|
+
cof_cli/convert.py,sha256=H6pyCDuJZBJEo3HytfRfybRuEtbazcsmrr-3yeBJ7mM,18712
|
|
6
|
+
cof_cli/migrate.py,sha256=1Cm8IUk-uf5gUDJi9yEJKr324mw1ugtHjr1Vt4YSbcY,14914
|
|
7
|
+
cof_cli/model.py,sha256=gGw0kMejeK6NhVCvll6J0nfFM5wcV39peuAg2F-UUsQ,20496
|
|
8
|
+
cof_cli/ops.py,sha256=SbRmWP_HjOnprxut368xk-ZRslaHgeH35tblFy8q2fA,21453
|
|
9
|
+
cof_cli/tokens.py,sha256=m3bV8kOdlSIKTilRqR60hbijJZyQCz7MUI8WPprdfvg,807
|
|
10
|
+
cof_cli/validate.py,sha256=gmJfzKVX24dElv9BvKKEjC8478fREtLIg15M-RNZZ4Q,62027
|
|
11
|
+
cof_cli/schemas/attitude.schema.json,sha256=NeOZ1cc_DJaiR7lrl4pCejWc_Z09Ikky8bFXc72DxKs,5622
|
|
12
|
+
cof_cli/schemas/body.schema.json,sha256=HrIlOAL4Bw3yy791VtEQve9xfiqJAD7K9pKXlsPPmSw,2187
|
|
13
|
+
cof_cli/schemas/card.schema.json,sha256=fg2v1VBYBCjHvqfnw9o-l9jsGWl_PFBqeef19phYW4M,2462
|
|
14
|
+
cof_cli/schemas/consent.schema.json,sha256=dsfAEMLlW9herz09MMAmAE1RCOOQmXCyhGIwdl7KUZo,2986
|
|
15
|
+
cof_cli/schemas/garments-1.0.json,sha256=iM3BGSVRWZBYQNgIiHiHw8n8IWUVp5I_NzU7EckMuf4,3398
|
|
16
|
+
cof_cli/schemas/hair.schema.json,sha256=k-U_9WaziQoYSpAa-d7GqIRXzNJLD0qD6sSx2e04Eik,2037
|
|
17
|
+
cof_cli/schemas/manifest.schema.json,sha256=OlUjrtI11qs4ooHuCbMDsFzvP9ohnle5RS00KymyK3E,43939
|
|
18
|
+
cof_cli/schemas/pose.schema.json,sha256=fjVwq9uBdn1JD0XS2l7DcYNvg56k0t7U3mBNhPOVJ8Y,4250
|
|
19
|
+
cof_cli/schemas/psyche.schema.json,sha256=1Z8gzJKNsXqybZAohXmph8d1bm95sAwJ8zj6K-oDsfw,6294
|
|
20
|
+
cof_cli/schemas/skeleton.schema.json,sha256=GUQJ5rN-dvdiNOGn510jXUAnO6MZAtLQpTguDZ6eCic,1774
|
|
21
|
+
cof_cli/schemas/visemes.schema.json,sha256=883lTaVZihSpyRyaLB6oGv2Z_TMu_ncHhxnz2H2jp_c,680
|
|
22
|
+
cof_cli/schemas/voice-profile.schema.json,sha256=RvJMCV-BhFbqvGvw2xevfQ7-C2q-tZwD_KZVZROzOZE,6480
|
|
23
|
+
cof_cli/schemas/weights.schema.json,sha256=oAk-WwKGVmW_JoFoVtpHLLKC2qHqBz7iDSYdrDA4d1Y,4247
|
|
24
|
+
cof_cli-1.0.0.dist-info/METADATA,sha256=L_GzPGrHHNeJoyG_u8_BbaZ-WcaZo3_VsGjjbEfCtuE,2399
|
|
25
|
+
cof_cli-1.0.0.dist-info/WHEEL,sha256=YVMoNqKzERt-wjUZwJ33xBGAwnFl-4cqbYkTtWa4itE,91
|
|
26
|
+
cof_cli-1.0.0.dist-info/entry_points.txt,sha256=--s_H5OTc8htSK0aHQZaiK4CYdmt2oZJQqaobOwXX7k,41
|
|
27
|
+
cof_cli-1.0.0.dist-info/top_level.txt,sha256=_UYaAC9UMqS28w8O1yyldasMwKInlA1mIORXHeVZQeQ,8
|
|
28
|
+
cof_cli-1.0.0.dist-info/RECORD,,
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
cof_cli
|