-
Marcus Schiesser authoredMarcus Schiesser authored
Code owners
Assign users and groups as approvers for specific file changes. Learn more.
llama3.ts 360 B
import { ReplicateLLM } from "llamaindex";
(async () => {
const tres = new ReplicateLLM({ model: "llama-3-70b-instruct" });
const stream = await tres.chat({
messages: [{ content: "Hello, world!", role: "user" }],
stream: true,
});
for await (const chunk of stream) {
process.stdout.write(chunk.delta);
}
console.log("\n\ndone");
})();