osai_core

Crates.ioosai_core
lib.rsosai_core
version0.1.0
created_at2025-07-17 15:39:19.860659+00
updated_at2025-07-17 15:39:19.860659+00
descriptionCore logic for OSAI browser-based AI systems
homepage
repository
max_upload_size
id1757718
size119,240
amyoshi (amyoshi-hub)

documentation

README

OSAI_core

osai_core is the low-level engine for the OSAI system, supporting AI interactions via WebSocket and HTTP. Designed for Raspberry Pi and local edge AI deployments.

Exsample

use osai_core::OSAI;
use std::io::{Write};
use std::io;

#[tokio::main]
async fn main() {

    println!("input command");
    let mut in_cmd = String::new();
    io::stdin().read_line(&mut in_cmd).unwrap();
    let cmd = in_cmd.trim();

    let  osai = OSAI::new();
    if cmd == "server"{
        let _ = osai.run().await;
    }else if cmd == "http_server"{
        OSAI::http_server().await;
    }else if cmd == "text" {
        OSAI::send_text_cli().await;
    }else{
        println!("no cmd"); 
    }
}

feature

  • run: luanch the OSAI server
  • http_server: luanch http_server serving file API
  • send_text: CLI interface for sending formatted OSAI messages
Commit count: 0

cargo fmt