
Research
PyPI Package Disguised as Instagram Growth Tool Harvests User Credentials
A deceptive PyPI package posing as an Instagram growth tool collects user credentials and sends them to third-party bot services.
@copilotkit/runtime
Advanced tools
To get started with CopilotKit, please check out the documentation.
CopilotKit now supports LangFuse logging integration to help you monitor, analyze, and debug your LLM requests and responses.
To enable LangFuse logging, you can configure it when initializing the CopilotRuntime:
import { CopilotRuntime, OpenAIAdapter } from "@copilotkit/runtime";
import { LangfuseClient } from "langfuse";
// Initialize your LangFuse client
const langfuse = new LangfuseClient({
publicKey: process.env.LANGFUSE_PUBLIC_KEY!,
secretKey: process.env.LANGFUSE_SECRET_KEY!,
baseUrl: process.env.LANGFUSE_BASE_URL,
});
// Create a CopilotRuntime with LangFuse logging enabled
const runtime = new CopilotRuntime({
adapter: new OpenAIAdapter({ apiKey: process.env.OPENAI_API_KEY }),
logging: {
enabled: true,
progressive: true, // Set to false for buffered logging
logger: {
logRequest: (data) => langfuse.trace({ name: "LLM Request", input: data }),
logResponse: (data) => langfuse.trace({ name: "LLM Response", output: data }),
logError: (errorData) => langfuse.trace({ name: "LLM Error", metadata: errorData }),
},
},
});
The logging configuration accepts the following options:
enabled
(boolean): Enable or disable logging (default: false)progressive
(boolean): When true, logs each chunk as it's streamed. When false, logs the complete response (default: true)logger
(object): Contains callback functions for logging:
logRequest
: Called when an LLM request is madelogResponse
: Called when an LLM response is receivedlogError
: Called when an error occurs during an LLM requestYou can integrate with any logging service by implementing the logger interface:
const runtime = new CopilotRuntime({
adapter: new OpenAIAdapter({ apiKey: "YOUR_API_KEY" }),
logging: {
enabled: true,
progressive: false,
logger: {
logRequest: (data) => {
// Implement your custom logging logic
console.log("LLM Request:", JSON.stringify(data));
},
logResponse: (data) => {
// Implement your custom logging logic
console.log("LLM Response:", JSON.stringify(data));
},
logError: (error) => {
// Implement your custom error logging
console.error("LLM Error:", error);
},
},
},
});
This allows you to send your logs to any system or service that you prefer.
FAQs
Unknown package
The npm package @copilotkit/runtime receives a total of 15,172 weekly downloads. As such, @copilotkit/runtime popularity was classified as popular.
We found that @copilotkit/runtime demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Research
A deceptive PyPI package posing as an Instagram growth tool collects user credentials and sends them to third-party bot services.
Product
Socket now supports pylock.toml, enabling secure, reproducible Python builds with advanced scanning and full alignment with PEP 751's new standard.
Security News
Research
Socket uncovered two npm packages that register hidden HTTP endpoints to delete all files on command.