MyGit

e2b-dev/E2B

Fork: 455 Star: 6956 (更新于 2024-11-04 20:30:09)

license: Apache-2.0

Language: TypeScript .

Secure open source cloud runtime for AI apps & AI agents

最后发布版本: @e2b/cli@0.5.10 ( 2024-08-27 17:30:28)

官方网址 GitHub网址

e2b logo

Last 1 month downloads for the Python SDK Last 1 month downloads for the JavaScript SDK

What is E2B?

E2B is an open-source infrastructure that allows you run to AI-generated code in secure isolated sandboxes in the cloud. To start and control sandboxes, use our JavaScript SDK or Python SDK.

[!NOTE] This repository contains the core E2B SDK that's used in our main E2B Code Interpreter SDK.

Run your first Sandbox

1. Install SDK

JavaScript / TypeScript

npm i @e2b/code-interpreter

Python

pip install e2b-code-interpreter

2. Get your E2B API key

  1. Sign up to E2B here.
  2. Get your API key here.
  3. Set environment variable with your API key
E2B_API_KEY=e2b_***

3. Execute code with code interpreter inside Sandbox

JavaScript / TypeScript

import { Sandbox } from '@e2b/code-interpreter'

const sandbox = await Sandbox.create()
await sbx.runCode('x = 1')

const execution = await sbx.runCode('x+=1; x')
console.log(execution.text)  // outputs 2

Python

from e2b_code_interpreter import Sandbox

with Sandbox() as sandbox:
    sandbox.run_code("x = 1")
    execution = sandbox.run_code("x+=1; x")
    print(execution.text)  # outputs 2

4. Check docs

Visit E2B documentation.

5. E2B cookbook

Visit our Cookbook to get inspired by examples with different LLMs and AI frameworks.

最近版本更新:(数据更新于 2024-09-11 21:26:07)

2024-08-27 17:30:28 @e2b/cli@0.5.10

2024-08-27 17:07:26 @e2b/cli@0.5.9

2024-08-07 17:52:57 @e2b/cli@0.5.8

2024-08-05 21:53:33 e2b@0.16.2

2024-08-05 21:53:30 @e2b/cli@0.5.7

2024-07-25 03:04:16 @e2b/cli@0.5.6

2024-06-11 19:56:47 @e2b/cli@0.5.5

2024-06-11 19:35:56 @e2b/cli@0.5.4

2024-05-31 23:03:14 @e2b/python-sdk@0.17.1

2024-05-10 07:35:25 e2b@0.16.1

主题(topics):

agent, ai, ai-agent, ai-agents, code-interpreter, copilot, development, devtools, gpt, gpt-4, javascript, llm, nextjs, openai, python, react, software, typescript

e2b-dev/E2B同语言 TypeScript最近更新仓库

2024-11-05 17:55:23 langgenius/dify

2024-11-05 16:59:32 laurent22/joplin

2024-11-05 11:52:31 RSSNext/Follow

2024-11-05 07:18:03 microsoft/genaiscript

2024-11-05 05:06:06 getmaxun/maxun

2024-11-04 14:44:09 x-extends/vxe-table