general idea and structure together

This commit is contained in:
Kewbit 2025-06-24 02:08:00 +07:00
parent c0c744ab35
commit e7924fd59f
2 changed files with 20 additions and 20 deletions

View file

@ -1,3 +1,7 @@
## 1.0.0 ## 0.1.0
- Initial version. - Initial version. (Experimental and WIP, do not use until a few versions later on)
## 0.1.1
- Readme clean up, from older name

View file

@ -1,5 +1,5 @@
# TorChat Dart Node # TorChat Dart SDK (Full Node)
<p align="center"> <p align="center">
<a href="https://haveno.com"><img src="https://foss.haveno.com/tor-project/torchat/raw/branch/main/assets/images/torchat-compressed-rounded.png" width=275 /></a> <a href="https://haveno.com"><img src="https://foss.haveno.com/tor-project/torchat/raw/branch/main/assets/images/torchat-compressed-rounded.png" width=275 /></a>
@ -7,12 +7,12 @@
---- ----
A full, cross-platform **Tor/Arti-powered** TorChat written 100 % in Dart. A full, cross-platform **Tor/Arti-powered** TorChat written 100% in Dart.
Spin it up on Windows, macOS, Linux—even mobile or Raspberry Pi—no C tool-chain, no hassle. Spin it up on Windows, macOS, Linux—even mobile or Raspberry Pi—no C tool-chain, no hassle, and most importantly, run a full node on your phone, without too much strain.
> **TL;DR** > **TL;DR**
> `dart pub global activate whisper_node` > `dart pub global activate torchat`
> `whisper_node run` > `torchat run`
> Voilà: a fully-functional relay + client with gRPC endpoints and a sweet high-level SDK. > Voilà: a fully-functional relay + client with gRPC endpoints and a sweet high-level SDK.
--- ---
@ -25,7 +25,7 @@ It exposes:
| Layer | Purpose | | Layer | Purpose |
|-------|---------| |-------|---------|
| **gRPC API** | Full power, language-agnostic. Auto-generated protobuf docs & stubs. | | **gRPC API** | Full power, language-agnostic. Auto-generated protobuf docs & stubs. |
| **Dart SDK** | High-level classes (`WhisperClient`, `WhisperRelay`, `GroupChat`, …). | | **Dart SDK** | High-level classes (`TorChatClient`, `TorChatRelay`, `GroupChat`, …). |
| **Tor/Arti wrapper** | Boots a hidden service automatically; no Tor install required. | | **Tor/Arti wrapper** | Boots a hidden service automatically; no Tor install required. |
Perfect for bots, CLIs, desktop apps, or embedding in Flutter. Perfect for bots, CLIs, desktop apps, or embedding in Flutter.
@ -35,7 +35,7 @@ Perfect for bots, CLIs, desktop apps, or embedding in Flutter.
## 🚀 Features ## 🚀 Features
* **Multi-platform** runs anywhere Dart VM runs ✔ * **Multi-platform** runs anywhere Dart VM runs ✔
* **Automatic Tor/Arti** `dart run whisper_node:tor` launches a hidden service for you ✔ * **Automatic Tor/Arti** `dart run torchat:tor` launches a hidden service for you ✔
* **gRPC over onion** multiplexed, binary, schema-safe ✔ * **gRPC over onion** multiplexed, binary, schema-safe ✔
* **Envelope store-and-forward** offline delivery with spam-PoW ✔ * **Envelope store-and-forward** offline delivery with spam-PoW ✔
* **Group chat** federated membership & signed admin events ✔ * **Group chat** federated membership & signed admin events ✔
@ -49,9 +49,9 @@ Perfect for bots, CLIs, desktop apps, or embedding in Flutter.
```bash ```bash
# 1. Install Dart ≥ 3.4 # 1. Install Dart ≥ 3.4
# 2. Install TorChat globally # 2. Install TorChat globally
dart pub global activate whisper_node dart pub global activate torchat
# 3. Run a node # 3. Run a node
whisper_node run torchat run
``` ```
First launch will: First launch will:
@ -64,11 +64,11 @@ First launch will:
## 🔧 Configuration ## 🔧 Configuration
`whisper_node.yaml` (auto-created in `$HOME/.whisper_node/`): `torchat.yaml` (auto-created in `$HOME/.torchat/`):
```yaml ```yaml
listen_port: 20900 listen_port: 20900
data_dir: ~/.whisper_node/data data_dir: ~/.torchat/data
tor: tor:
enabled: true enabled: true
socks_port: 9050 # 0 = random socks_port: 9050 # 0 = random
@ -101,7 +101,7 @@ grpcurl -plaintext -protoset out/descriptor.pb \
## 🛠️ Dart SDK snippet ## 🛠️ Dart SDK snippet
```dart ```dart
import 'package:whisper_node/whisper.dart'; import 'package:torchat/torchat.dart';
void main() async { void main() async {
final node = await TorChat.bootstrap(); // starts Tor + gRPC final node = await TorChat.bootstrap(); // starts Tor + gRPC
@ -133,7 +133,7 @@ void main() async {
## 🤝 Contributing ## 🤝 Contributing
1. `git clone https://foss.haveno.com/haveno-network/whisper_node_dart` 1. `git clone https://foss.haveno.com/haveno-network/dart-torchat`
2. `dart pub get` 2. `dart pub get`
3. `dart test` 3. `dart test`
4. PRs welcome — keep commits sign-off (`-s`) for DCO. 4. PRs welcome — keep commits sign-off (`-s`) for DCO.
@ -142,8 +142,4 @@ void main() async {
## 🛡 License ## 🛡 License
AGPL-3.0-or-later — code wants to stay free. Apache-2.0
> _“They can block the site, they can censor the net — but they cant stop the whisper.”_
---