This commit is contained in:
Dax Raad
2025-05-18 14:13:04 -04:00
parent bcd2fd68b7
commit 0e303e6508
12 changed files with 493 additions and 144 deletions

View File

@@ -1,29 +1,11 @@
import { App } from "./app";
import process from "node:process";
import { RPC } from "./server/server";
import { Session } from "./session/session";
import { Identifier } from "./id/id";
import { Server } from "./server/server";
const app = await App.create({
directory: process.cwd(),
});
App.provide(app, async () => {
const sessionID = await Session.list()
[Symbol.asyncIterator]()
.next()
.then((v) => v.value ?? Session.create().then((s) => s.id));
await Session.chat(sessionID, {
role: "user",
id: Identifier.ascending("message"),
parts: [
{
type: "text",
text: "Hey how are you? try to use tools",
},
],
});
const rpc = RPC.listen();
const server = Server.listen();
});