https://github.com/asim/mu
A muslim app platform
https://github.com/asim/mu
Last synced: 7 months ago
JSON representation
A muslim app platform
- Host: GitHub
- URL: https://github.com/asim/mu
- Owner: asim
- License: apache-2.0
- Created: 2024-10-08T11:04:40.000Z (almost 2 years ago)
- Default Branch: main
- Last Pushed: 2024-10-28T21:39:56.000Z (almost 2 years ago)
- Last Synced: 2024-12-16T04:42:43.506Z (over 1 year ago)
- Language: Go
- Homepage:
- Size: 554 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- Changelog: news/.github/workflows/go.yml
- Funding: .github/FUNDING.yml
- License: LICENSE
Awesome Lists containing this project
README
# mu
The Micro Network
## Overview
A personal app platform that provides services without ads, algorithms, or tracking.
### Features
- **App** - Progressive web app for desktop and mobile
- **API** - Basic API for docs and programmatic access
- **Home** - One place to catchup with everything
- **Blog** - Microblogging and community sharing
- **Chat** - AI assistant with contextual discussions
- **Mail** - Private messaging and email inbox
- **News** - Curated RSS feeds and market data
- **Video** - YouTube search and Ad-free viewing
Mu runs as a single Go binary on your own server or use the hosted version at [mu.xyz](https://mu.xyz).
## Rationale
I'm tired of big tech platforms. We can't control any of them. Lots of addictive tendencies. It seems easier to turn them into API and data providers and rebuild the UX on top. Starting with blog, chat, news, mail and video.
## Roadmap
Starting with:
- [x] API - Basic API
- [x] App - Basic PWA
- [x] Home - Overview
- [x] Blog - Micro blogging
- [x] Chat - LLM chat UI
- [x] News - RSS news feed
- [x] Video - YouTube search
- [x] Mail - Private messaging
Coming soon:
- [ ] Wallet - Credits for usage
- [ ] Utilities - QR code scanner, etc
- [ ] Services - Marketplace of services
## Screenshots
### Home

[View more](docs/SCREENSHOTS.md)
## Concepts
Basic concepts. The app contains **cards** displayed on the home screen. These are a sort of summary or overview. Each card links to a **micro app** or an external website. For example the latest Video "more" links to the /video page with videos by channel and search, whereas the markets card redirects to an external app.
## Free Hosting
**Mu is free to use** at [mu.xyz](https://mu.xyz). Create an account and start using it immediately - no credit card required.
## Paid Hosting
Contact asim@mu.xyz or file an issue to discuss managed hosting.
## Self Hosting
Ensure you have [Go](https://go.dev/doc/install) installed
Set your Go bin
```
export PATH=$HOME/go/bin:$PATH
```
Download and install Mu
```
git clone https://github.com/asim/mu
cd mu && go install
```
### Configuration
To reconfigure prompts, topics, cards, etc you can adjust the following json files.
Note: The binary will need to be recompiled as they are embedded at build time.
#### Chat Prompts
Set the chat prompts in chat/prompts.json
#### Home Cards
Set the home cards in home/cards.json
#### News Feed
Set the RSS news feeds in news/feeds.json
#### Video Channels
Set the YouTube video channels in video/channels.json
### API Keys
We need API keys for the following
#### Video Search
- [Youtube Data](https://developers.google.com/youtube/v3)
```
export YOUTUBE_API_KEY=xxx
```
#### Chat Model
**Ollama (Default)**
By default, Mu uses [Ollama](https://ollama.ai/) for LLM queries. Install and run Ollama locally:
```
# Install Ollama from https://ollama.ai/
# Pull a model (e.g., llama3.2)
ollama pull llama3.2
# Ollama runs on http://localhost:11434 by default
```
Optional environment variables:
```
export MODEL_NAME=llama3.2 # Default model
export MODEL_API_URL=http://localhost:11434 # Ollama API URL
```
**Fanar (Optional)**
Alternatively, use [Fanar](https://fanar.qa/) by setting the API key:
```
export FANAR_API_KEY=xxx
export FANAR_API_URL=https://api.fanar.qa # Optional, this is the default
```
When `FANAR_API_KEY` is set, Mu will use Fanar instead of Ollama.
**Note:** Fanar has a rate limit of 10 requests per minute. Mu enforces this limit automatically.
**Anthropic Claude (Optional)**
You can also use Anthropic's Claude API:
```
export ANTHROPIC_API_KEY=xxx
export ANTHROPIC_MODEL=claude-haiku-4.5-20250311 # Optional, this is the default
```
Priority order: Anthropic > Fanar > Ollama
For vector search see this [doc](docs/VECTOR_SEARCH.md)
### Data Storage
By default, Mu stores search index and embeddings in JSON files loaded into memory. For production use with large datasets, enable SQLite storage to reduce memory usage:
```
export MU_USE_SQLITE=1
```
This stores the search index and embeddings in SQLite (`~/.mu/data/index.db`) instead of RAM. Migration from JSON happens automatically on first startup.
### Run
Then run the app
```
mu --serve
```
Go to localhost:8081
## Documentation
Additional documentation is available in the [docs](docs/) folder:
- [Design Documentation](docs/DESIGN.md) - Architecture and design decisions
- [Messaging System](docs/MESSAGING_SYSTEM.md) - Complete messaging and mail setup guide
- [Environment Variables](docs/ENVIRONMENT_VARIABLES.md) - All configuration options
- [Contextual Discussions](docs/CONTEXTUAL_DISCUSSIONS.md) - Chat context and discussion features
- [Vector Search](docs/VECTOR_SEARCH.md) - Setting up vector embeddings for semantic search
- [Screenshots](docs/SCREENSHOTS.md) - Application screenshots
## Development
### Git Hooks
Install git hooks to run tests before commits:
```bash
./scripts/install-hooks.sh
```
This will prevent commits if tests fail, helping catch regressions early. See [scripts/README.md](scripts/README.md) for more details.
### Contributing
Join [Discord](https://discord.gg/jwTYuUVAGh) if you'd like to work on this.
## Sponsorship
You can sponsor the project using [GitHub Sponsors](https://github.com/sponsors/asim) or via [Patreon](https://patreon.com/muxyz) to support ongoing development and hosting costs. Patreon members get access to premium features like Mail, early access to new features, and vote on the project roadmap. Most features remain free for all users.
## License
Mu is licensed under the [GNU Affero General Public License v3.0 (AGPL-3.0)](LICENSE).
This means you are free to use, modify, and distribute this software, but if you run a modified version on a server and let others interact with it, you must make your modified source code available under the same license.