Telegram Group & Telegram Channel
🦀 Инструмент разработки портативных, модульных и легких Fullstack агентов

cargo add rig-core


rust 
use rig::{completion::Prompt, providers::openai};

#[tokio::main]
async fn main() {
// Create OpenAI client and model
// This requires the `OPENAI_API_KEY` environment variable to be set.
let openai_client = openai::Client::from_env();

let gpt4 = openai_client.agent("gpt-4").build();

// Prompt the model and print its response
let response = gpt4
.prompt("Who are you?")
.await
.expect("Failed to prompt GPT-4");

println!("GPT-4: {response}");
}

★ 2378

🖥 Github

@rust_code
Please open Telegram to view this post
VIEW IN TELEGRAM



tg-me.com/rust_code/846
Create:
Last Update:

🦀 Инструмент разработки портативных, модульных и легких Fullstack агентов

cargo add rig-core


rust 
use rig::{completion::Prompt, providers::openai};

#[tokio::main]
async fn main() {
// Create OpenAI client and model
// This requires the `OPENAI_API_KEY` environment variable to be set.
let openai_client = openai::Client::from_env();

let gpt4 = openai_client.agent("gpt-4").build();

// Prompt the model and print its response
let response = gpt4
.prompt("Who are you?")
.await
.expect("Failed to prompt GPT-4");

println!("GPT-4: {response}");
}

★ 2378

🖥 Github

@rust_code

BY Rust




Share with your friend now:
tg-me.com/rust_code/846

View MORE
Open in Telegram


Rust Telegram | DID YOU KNOW?

Date: |

How to Use Bitcoin?

n the U.S. people generally use Bitcoin as an alternative investment, helping diversify a portfolio apart from stocks and bonds. You can also use Bitcoin to make purchases, but the number of vendors that accept the cryptocurrency is still limited. Big companies that accept Bitcoin include Overstock, AT&T and Twitch. You may also find that some small local retailers or certain websites take Bitcoin, but you’ll have to do some digging. That said, PayPal has announced that it will enable cryptocurrency as a funding source for purchases this year, financing purchases by automatically converting crypto holdings to fiat currency for users. “They have 346 million users and they’re connected to 26 million merchants,” says Spencer Montgomery, founder of Uinta Crypto Consulting. “It’s huge.”

Telegram today rolling out an update which brings with it several new features.The update also adds interactive emoji. When you send one of the select animated emoji in chat, you can now tap on it to initiate a full screen animation. The update also adds interactive emoji. When you send one of the select animated emoji in chat, you can now tap on it to initiate a full screen animation. This is then visible to you or anyone else who's also present in chat at the moment. The animations are also accompanied by vibrations. This is then visible to you or anyone else who's also present in chat at the moment. The animations are also accompanied by vibrations.

Rust from jp


Telegram Rust
FROM USA