|
| 1 | +# SKaiNET-transformers |
| 2 | + |
| 3 | +SKaiNET-transformers is a high-performance LLM (Large Language Model) application layer built on top of the [SKaiNET](https://github.com/SKaiNET-developers/SKaiNET.git) engine. It provides a set of runtimes and CLI tools for various transformer-based models, optimized for Kotlin Multiplatform. |
| 4 | + |
| 5 | +## Key Features |
| 6 | + |
| 7 | +- **Multi-Model Support**: Implementations for popular architectures including Llama, Gemma, Qwen, and BERT. |
| 8 | +- **Engineered for Performance**: Uses the SKaiNET library as its core inference engine, leveraging hardware acceleration where available. |
| 9 | +- **Kotlin Multiplatform**: Designed to run across different platforms (JVM, Native, Android, etc.). |
| 10 | +- **Efficient Weights Loading**: Support for `safetensors` format for fast and safe model loading. |
| 11 | + |
| 12 | +## Project Structure |
| 13 | + |
| 14 | +- `llm-core`: Core abstractions and base classes for LLM components. |
| 15 | +- `llm-inference`: Model-specific inference logic (Llama, BERT, Gemma, Qwen). |
| 16 | +- `llm-runtime`: Platform-specific runtime implementations. |
| 17 | +- `llm-apps`: Ready-to-use CLI applications for model interaction and testing. |
| 18 | +- `llm-agent`: High-level agentic capabilities (in development). |
| 19 | + |
| 20 | +## Getting Started |
| 21 | + |
| 22 | +### Prerequisites |
| 23 | + |
| 24 | +- JDK 17 or higher |
| 25 | +- Gradle |
| 26 | + |
| 27 | +### Running the CLI Tools |
| 28 | + |
| 29 | +You can run the provided CLI tools using Gradle. For example, to run the BERT CLI: |
| 30 | + |
| 31 | +```bash |
| 32 | +./gradlew :llm-apps:kbert-cli:run --args="/path/to/model-dir 'query text'" |
| 33 | +``` |
| 34 | + |
| 35 | +Replace `/path/to/model-dir` with a directory containing `model.safetensors`, `vocab.txt`, and `config.json`. |
| 36 | + |
| 37 | +## Engine |
| 38 | + |
| 39 | +This project uses **SKaiNET** as its underlying execution engine. |
| 40 | +GitHub: [https://github.com/SKaiNET-developers/SKaiNET](https://github.com/SKaiNET-developers/SKaiNET.git) |
| 41 | + |
| 42 | +## License |
| 43 | + |
| 44 | +[Add License Information Here] |
0 commit comments