Text Generation
Transformers
ONNX
PyTorch
English
symbolic-decoder
aletheia
philosophical-agi
gnai-creator
Run this model with HF Jobs
Run gnai-creator/noesis-decoder on Hugging Face's managed compute, monitor its progress, and retrieve the results when it's done.
Paste one of these prompts into your coding agent:
Fine-tune on my dataset
Use HF Jobs and TRL to fine-tune https://huggingface.co/gnai-creator/noesis-decoder. Ask me which dataset to train on, then push the fine-tuned model to a new model repo. Run `hf jobs --help` first to learn the CLI.
Run batch inference
Use HF Jobs to run batch inference with https://huggingface.co/gnai-creator/noesis-decoder on the inputs in a mounted HF Bucket. Ask me which Bucket to use, then write the outputs back to it and keep each input ID. Run `hf jobs --help` first to learn the CLI.
Evaluate on a benchmark
Use HF Jobs to evaluate https://huggingface.co/gnai-creator/noesis-decoder. Ask me which benchmark to run, then save the scores and the per-example results to a new dataset repo. Run `hf jobs --help` first to learn the CLI.
Quantize for lower memory use
Use HF Jobs to create a 4-bit version of https://huggingface.co/gnai-creator/noesis-decoder. Push it to a new model repo, then reload it from there and report its memory footprint. Run `hf jobs --help` first to learn the CLI.
Instructions to use gnai-creator/noesis-decoder with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use gnai-creator/noesis-decoder with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="gnai-creator/noesis-decoder")# pip install -U transformers accelerate # Load model directly from transformers import AutoModel model = AutoModel.from_pretrained("gnai-creator/noesis-decoder", device_map="auto") - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- vLLM
How to use gnai-creator/noesis-decoder with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "gnai-creator/noesis-decoder" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "gnai-creator/noesis-decoder", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }'Use Docker
docker model run hf.co/gnai-creator/noesis-decoder
- SGLang
How to use gnai-creator/noesis-decoder with SGLang:
Install from pip and serve model
# Install SGLang from pip: pip install sglang # Start the SGLang server: python3 -m sglang.launch_server \ --model-path "gnai-creator/noesis-decoder" \ --host 0.0.0.0 \ --port 30000 # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:30000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "gnai-creator/noesis-decoder", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }'Use Docker images
docker run --gpus all \ --shm-size 32g \ -p 30000:30000 \ -v ~/.cache/huggingface:/root/.cache/huggingface \ --env "HF_TOKEN=<secret>" \ --ipc=host \ lmsysorg/sglang:latest \ python3 -m sglang.launch_server \ --model-path "gnai-creator/noesis-decoder" \ --host 0.0.0.0 \ --port 30000 # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:30000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "gnai-creator/noesis-decoder", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }' - Docker Model Runner
How to use gnai-creator/noesis-decoder with Docker Model Runner:
docker model run hf.co/gnai-creator/noesis-decoder
Update README.md
Browse files14 unmodified lines151617181819202021222322242526272425262728292930313132333334343536363738383940413940414243444546474849504351525354554556575859606162474863646566676869707172737475517677787980818283848586878889909192939495969798539910055565758101102103104105601061071081091101111121131141151161171181191206212112214 unmodified linespipeline_tag: text-generation---
# Aletheia Noesis Decoder# 🧠 Noesis Decoder (AletheiaEngine)
Noesis é o decoder proprietário da AletheiaEngine. Ele traduz estados simbólicos \(\psi_s\) em linguagem natural garantindo a coerência epistemológica medida pela **Qualidade da Verdade (Q)**. Diferente de abordagens puramente estatísticas, o Noesis prioriza a fidelidade semântica entre a intenção simbólica e o texto gerado.**Repository:** [gnai-creator/noesis-decoder](https://huggingface.co/gnai-creator/noesis-decoder)**Author:** Felipe M. Muniz (`gnai-creator`)**License:** Apache-2.0
## Arquitetura---
## 🔍 Overview
- **Transformer Decoder** com 8 camadas e atenção cruzada condicionada por \(\psi_s\) e estados contínuos.- Entradas: vetor de intenção `psi_s`, memória lenta `state` opcional e sequência de tokens.- Saídas: `logits`, embedding semântico `z_text` e métrica \(\hat{Q}\).- Função de perda combina cross-entropy, coerência Q e penalizações de restrições.**Noesis Decoder** is the proprietary symbolic decoder of **AletheiaEngine** — a hybrid symbolic–neural system designed for *philosophical artificial general intelligence*.
## API FastAPIUnlike conventional text generators, Noesis translates **symbolic embeddings (ψₛ)** into meaningful language based on *epistemic coherence*, rather than statistical prediction.
O pacote inclui a aplicação `aletheia_decoder.api.app` com duas rotas:---
- `POST /generate`: recebe `psi_s`, `state`, `constraints`, prompts opcionais e parâmetros de decodificação. Retorna texto gerado, tokens, \(\hat{Q}\) e metadados.- `POST /train`: permite fine-tuning local a partir de um dataset JSONL.## ⚙️ Model Architecture
### Execução local* **Framework:** PyTorch → ONNX Runtime* **Files:**
```bashpip install -r requirements.txtuvicorn aletheia_decoder.api.app:app --host 0.0.0.0 --port 8000``` * `model_infer.onnx` – Inference model (optimized) * `noesis.pt` – PyTorch checkpoint (training artifact) * `inference.py` – Custom ONNX handler* **Input:** float32 symbolic vector, shape `[1, D]`* **Output:** decoded float or token embeddings (depending on context)
---
## 🧩 Example Usage
### 🔹 Python + ONNX Runtime
## Treinamento```pythonfrom huggingface_hub import hf_hub_downloadimport onnxruntime as ortimport numpy as np
Use o script `aletheia_decoder/model/train.py` para treinar o modelo com dados anotados:# Download ONNX modelonnx_path = hf_hub_download( repo_id="gnai-creator/noesis-decoder", filename="model_infer.onnx", repo_type="model")
```bashpython -m aletheia_decoder.model.train data/dataset.jsonl --epochs 200 --batch-size 4 --lr 3e-5# Load runtimesess = ort.InferenceSession(onnx_path, providers=["CPUExecutionProvider"])input_name = sess.get_inputs()[0].nameoutput_name = sess.get_outputs()[0].name
# Example symbolic vector ψₛx = np.random.randn(1, 300).astype("float32")
# Run inferencey = sess.run([output_name], {input_name: x})[0]print("Output shape:", y.shape)```
Os checkpoints podem ser salvos com `torch.save(model.state_dict(), "noesis.pt")` e exportados para ONNX se necessário.---
## 💡 Training Data
Trained on **symbolic text pairs** generated from philosophical, logical, and reflective corpora within the AletheiaEngine ecosystem.Goal: alignment between **symbolic intention (ψₛ)** and **natural language output**.
---
## 📊 Metrics (Indicative)
| Metric | Value | Description || ------------- | ------------ | ------------------------------------------ || Cosine(Q) | 0.83 | Symbolic alignment measure || Perplexity | 2.41 | Statistical readability proxy || Latency (CPU) | ~28 ms/token | Inference on Intel Sapphire Rapids (1vCPU) |
---
## 🚀 Deployment
This model is compatible with **Hugging Face Inference Endpoints** using the `Default` engine and the included `handler.py` handler.
## Deploy no Hugging Face SpacesRecommended hardware:
1. Faça fork deste diretório para um repositório separado.2. Configure o Space no modo **FastAPI** apontando para `app:app`.3. Defina as variáveis de ambiente de acordo com sua infraestrutura (ex.: `DECODER_ENDPOINT`).4. Opcionalmente publique checkpoints `.pt` e `.onnx` nos assets do Space.* **CPU:** Intel Sapphire Rapids (1vCPU / 2GB)* **GPU:** NVIDIA T4 for larger batch inference
---
## Slogan## ⚠️ Limitations
* Not a conventional LLM — requires symbolic vectors as input.* Outputs are contextualized to Aletheia’s symbolic reasoning pipeline.* Not suited for free-form text generation.
---
## 📜 License
This repository is distributed under the **Apache License 2.0**.See [LICENSE](./LICENSE) for details.
---
> **Noesis — onde a intenção se torna linguagem.**> *“Truth is not imposed; it emerges from alignment.”*> — *Felipe M. Muniz (2025)*README.md+88-28