Skip to main content

cgh-classify

Human-trainable confidentiality classification for cgh. You label a few files, a lightweight local model (TF-IDF + naive Bayes, standard library only) generalizes to the rest, and the egress gate and guard enforce the result. Nothing ever leaves the machine.

pip install cgh-classify
cgh classify label payroll.xlsx            # mark confidential
cgh classify label README.md --not         # mark public
cgh classify train                         # fit + sweep the repo
cgh classify review                        # files the model is unsure about
cgh findings --key confidential

How labels and predictions interact

Source Finding written Effect on the egress gate
Human label, confidential confidential = true (block) blocked everywhere
Human label, public confidential = false allowlisted, including strict mode
Model prediction, confidential confidential = true (block) blocked everywhere
Model prediction, public confidential.predicted = false no effect

The asymmetry is deliberate: a model may block on its own say-so (worst case, a false positive costs a summary), but only a human label can clear a file in mode = "secure", where the gate is an allowlist.

Configuration

[plugin.classify]
# threshold = 0.7      # predict confidential above this probability
# uncertain_low = 0.35 # review window lower bound
# uncertain_high = 0.65

Your labels are the asset: they live in .codegraph/classify_labels.json, the trained model in .codegraph/classify_model.json, both machine-local and cheap to retrain (cgh classify train is instant on thousands of files).

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

cgh_classify-0.1.0.tar.gz (9.6 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

cgh_classify-0.1.0-py3-none-any.whl (9.3 kB view details)

Uploaded Python 3

File details

Details for the file cgh_classify-0.1.0.tar.gz.

File metadata

  • Download URL: cgh_classify-0.1.0.tar.gz
  • Upload date:
  • Size: 9.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.14

File hashes

Hashes for cgh_classify-0.1.0.tar.gz
Algorithm Hash digest
SHA256 0b1d3718cc6fa7c60d08f52009f1ea53cbc5c1e9b66d37a4dccf6f75ba5df242
MD5 dbce6cec4d6929ea3ec2dc94c9617a70
BLAKE2b-256 3f2f96026b9581ba25b82cff5afadfb169247855b183c920545e04c8dc13fdbe

See more details on using hashes here.

Provenance

The following attestation bundles were made for cgh_classify-0.1.0.tar.gz:

Publisher: release.yml on altikva/cgh

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file cgh_classify-0.1.0-py3-none-any.whl.

File metadata

  • Download URL: cgh_classify-0.1.0-py3-none-any.whl
  • Upload date:
  • Size: 9.3 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.14

File hashes

Hashes for cgh_classify-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 7863486f3537bb3d9077efbb9e03bb892e0e8ffc322bf25b614ea14d7157253a
MD5 bda6b5ccb872cdd7c588ef4c8f21ab39
BLAKE2b-256 7efce36ed4c48507513bbe1a8864d4ccf2df7be3e10b86387b7afdfbd738b3a1

See more details on using hashes here.

Provenance

The following attestation bundles were made for cgh_classify-0.1.0-py3-none-any.whl:

Publisher: release.yml on altikva/cgh

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Release history Release notifications | RSS feed

0.1.3

2 files

0.1.2

2 files

0.1.1

2 files

This release

0.1.0 This release

2 files

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page