Skip to content

Commit 74846de

Browse files
committed
Added readme and license
1 parent b3c4167 commit 74846de

File tree

3 files changed

+131
-26
lines changed

3 files changed

+131
-26
lines changed

LICENSE

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
MIT License
2+
3+
Copyright (c) 2025 Cloud Code AI Inc.
4+
5+
Permission is hereby granted, free of charge, to any person obtaining a copy
6+
of this software and associated documentation files (the "Software"), to deal
7+
in the Software without restriction, including without limitation the rights
8+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9+
copies of the Software, and to permit persons to whom the Software is
10+
furnished to do so, subject to the following conditions:
11+
12+
The above copyright notice and this permission notice shall be included in all
13+
copies or substantial portions of the Software.
14+
15+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21+
SOFTWARE.

README.md

Lines changed: 110 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,110 @@
1-
# BrowserAI
2-
Bring powere of AI into browser
1+
# BrowserAI 🚀
2+
3+
Bring the power of AI directly into your browser! BrowserAI is a lightweight JavaScript library that enables running AI models directly in the browser using WebGPU acceleration.
4+
5+
## ✨ Features
6+
7+
- 🎯 Run AI models directly in the browser - no server required!
8+
- ⚡ WebGPU acceleration for blazing fast inference
9+
- 🔄 Seamless switching between MLC and Transformers engines
10+
- 📦 Pre-configured popular models ready to use
11+
- 🛠️ Easy-to-use API for text generation and more
12+
13+
## 🚀 Quick Start
14+
```
15+
bash
16+
npm install @browserai/browserai
17+
```
18+
19+
OR
20+
```
21+
bash
22+
yarn add @browserai/browserai
23+
```
24+
25+
### Basic Usage
26+
27+
```javascript
28+
import { BrowserAI } from '@browserai/browserai';
29+
30+
const browserAI = new BrowserAI();
31+
32+
browserAI.loadModel('llama-3.2-1b-instruct');
33+
34+
const response = await browserAI.generateText('Hello, how are you?');
35+
console.log(response);
36+
```
37+
38+
39+
## 📚 Examples
40+
41+
### Text Generation with Custom Parameters
42+
```javascript
43+
const ai = new BrowserAI();
44+
await ai.loadModel('llama-3.2-1b-instruct', {
45+
quantization: 'q4f16_1' // Optimize for size/speed
46+
});
47+
const response = await ai.generateText('Write a short poem about coding', {
48+
temperature: 0.8,
49+
maxTokens: 100
50+
});
51+
```
52+
53+
## 🔧 Supported Models
54+
55+
### MLC Models
56+
- Llama-3.2-1b-Instruct
57+
- SmolLM2-135M-Instruct
58+
- SmolLM2-350M-Instruct
59+
60+
### Transformers Models
61+
- Llama-3.2-1b-Instruct
62+
- DistilBERT (Sentiment Analysis)
63+
64+
## 🗺️ Enhanced Roadmap
65+
66+
### Phase 1: Foundation
67+
- 🎯 Simplified model initialization
68+
- 📊 Basic monitoring and metrics
69+
- 🔍 Simple RAG implementation
70+
- 🛠️ Developer tools integration
71+
72+
### Phase 2: Advanced Features
73+
- 📚 Enhanced RAG capabilities
74+
- Hybrid search
75+
- Auto-chunking
76+
- Source tracking
77+
- 📊 Advanced observability
78+
- Performance dashboards
79+
- Memory profiling
80+
- Error tracking
81+
82+
### Phase 3: Enterprise Features
83+
- 🔐 Security features
84+
- 🌐 Distributed processing
85+
- 📈 Advanced analytics
86+
- 🤝 Multi-model orchestration
87+
88+
## 🤝 Contributing
89+
90+
We welcome contributions! Feel free to:
91+
92+
1. Fork the repository
93+
2. Create your feature branch (`git checkout -b feature/amazing-feature`)
94+
3. Commit your changes (`git commit -m 'Add amazing feature'`)
95+
4. Push to the branch (`git push origin feature/amazing-feature`)
96+
5. Open a Pull Request
97+
98+
## 📄 License
99+
100+
This project is licensed under the MIT License - see the [LICENSE](LICENSE) file for details.
101+
102+
## 🙏 Acknowledgments
103+
104+
- [MLC AI](https://mlc.ai/) for their incredible mode compilation library and support for webgpu runtime and xgrammar
105+
- [Hugging Face](https://huggingface.co/) for their Transformers.js library
106+
- All our contributors and supporters!
107+
108+
---
109+
110+
<p align="center">Made with ❤️ for the AI community</p>

examples/nodejs/index.js

Lines changed: 0 additions & 24 deletions
This file was deleted.

0 commit comments

Comments
 (0)