Run this model with HF Jobs
Run i3-lab/i3-tiny 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/i3-lab/i3-tiny. 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/i3-lab/i3-tiny 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/i3-lab/i3-tiny. 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/i3-lab/i3-tiny. 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 i3-lab/i3-tiny with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use i3-lab/i3-tiny with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="i3-lab/i3-tiny", trust_remote_code=True)# pip install -U transformers accelerate # Load model directly from transformers import i3 model = i3.from_pretrained("i3-lab/i3-tiny", trust_remote_code=True, device_map="auto") - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- vLLM
How to use i3-lab/i3-tiny with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "i3-lab/i3-tiny" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "i3-lab/i3-tiny", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }'Use Docker
docker model run hf.co/i3-lab/i3-tiny
- SGLang
How to use i3-lab/i3-tiny 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 "i3-lab/i3-tiny" \ --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": "i3-lab/i3-tiny", "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 "i3-lab/i3-tiny" \ --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": "i3-lab/i3-tiny", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }' - Docker Model Runner
How to use i3-lab/i3-tiny with Docker Model Runner:
docker model run hf.co/i3-lab/i3-tiny
Update README.md
Browse files123---license: apache-2.0---12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394---license: apache-2.0language:- enpipeline_tag: text-generationlibrary_name: transformerstags:- i3-arhitecture---# i3-tiny: The i3 Architecture (v1)## Model DescriptionThe **i3-tiny** is an experimental Large Language Model (LLM) utilizing the proprietary **i3 (Integrated Intelligent Infrastructure)** Architecture. It is designed for ultra-efficiency and a low memory footprint.This model is a **character-level autoregressive decoder** trained on a small English corpus.---## Key Architectural FeaturesThe **i3 Block** is a novel, single-layer design that achieves high efficiency by minimizing parameter and computational costs. It integrates advanced mechanisms for sequence processing:* **Proprietary Recurrence Mechanism:**A specialized hybrid recurrence component manages sequential dependencies efficiently, avoiding the quadratic complexity of standard self-attention.* **Low-Rank Attention:**Attention mechanisms use highly factorized, low-rank projections, significantly reducing memory and compute costs associated with Key, Query, and Value matrices.* **Low-Rank Feedforward:**The standard FFN is replaced by proprietary low-rank factorization layers to maximize parameter efficiency throughout the block.---## Model Scale (v1 Configuration)| **Parameter** | **Value** | **Notes** || ------------------- | ------------------------- | -------------------------------------------------- || **Model Size** | Approx. 40–50M parameters | Exact count is printed during training initiation. || **d_model** | 256 | Hidden dimension size. || **n_layers** | 6 | Number of hybrid i3 blocks. || **n_heads** | 8 | Number of attention heads. || **Recurrence Rank** | 16 (d_state for Mamba) | Size of the proprietary recurrence state. || **Low-Rank Rank** | 8 | Rank used for low-rank factorizations. |---## Intended Uses and Limitations### Intended Uses* **Benchmarking & Research:** Exploring the training speed and final loss achievement of the i3 architecture against fully Transformer-based models of similar scale.* **Proof of Concept:** Demonstrating an ultra-efficient training and inference paradigm.### Out-of-Scope Use and Limitations* **Production Use:** *Do not* use this model for real-world text generation, translation, or conversation.* **General Language Tasks:** Due to the extremely small and repetitive training dataset (even with 10× repetition), the model has a very limited understanding of grammar, syntax, and semantics. It will primarily generate repetitive and fragmented text based on corpus patterns.---## Training Details### Training Data| **Parameter** | **Value** | **Notes** || ----------------- | ------------------------- | ------------------------------------------------------------------------- || **Source** | Public Domain Sample Text | The original sample text provided in the source code. || **Volume** | 10× Repetition | The original text was repeated 10 times to increase training data volume. || **Tokenization** | Character-level | Vocabulary size is determined by unique characters (≈32–35). || **Preprocessing** | Lowercased | All training data is normalized to lowercase characters. |---### Hyperparameters| **Parameter** | **Value** | **Notes** || ------------------- | ------------------ | --------- || **Optimization** | AdamW | || **Learning Rate** | 3e-4 | || **Max Iterations** | 2000 | || **Batch Size** | 2 | || **Sequence Length** | 128 | || **Loss Function** | Cross-Entropy Loss | |---## Performance Metrics* **Initial Loss (Expected):**The model should start with a Cross-Entropy Loss between **3.0** and **4.0**, depending on the final character vocabulary size (≈ ln V).* **Target Loss:**With the increased data volume (10×), the model should drop the training loss well below **2.0** and aim closer to **1.0** to be considered successfully trained and leveraging its increased capacity.
README.md+94-3