
Security News
New CVE Forecasting Tool Predicts 47,000 Disclosures in 2025
CVEForecast.org uses machine learning to project a record-breaking surge in vulnerability disclosures in 2025.
@7-docs/edge
Advanced tools
Dependency-free package for 7-docs to query your content from anywhere JavaScript can run
Query your content from anywhere JavaScript runs.
After ingesting content using @7-docs/cli, request "chat completions" using @7-docs/edge
.
No dependencies, uses fetch()
.
Curently there are adapters for Pinecone and Supabase. Pull requests to add more are welcome.
import { getCompletionHandler, pinecone } from 'https://esm.sh/@7-docs/edge'; // from '@7-docs/edge' in Node.js
const namespace = 'namespace-within-pinecone-index';
const system = 'Answer the question using the provided context.';
const prompt = `Context: {CONTEXT}
Question: {QUERY}
Answer: `;
const query = (vector: number[]) =>
pinecone.query({
url: PINECONE_URL,
token: PINECONE_API_KEY,
vector,
namespace
});
const handler = getCompletionHandler({ OPENAI_API_KEY, query, system, prompt });
export function GET(req: Request) {
return handler(req);
}
import { getCompletionHandler, supabase } from 'https://esm.sh/@7-docs/edge'; // from '@7-docs/edge' in Node.js
import { createClient } from 'https://esm.sh/@supabase/supabase-js'; // from '@supabase/supabase-js' in Node.js
const namespace = 'table-in-supabase';
const system = 'Answer the question using the provided context.';
const prompt = `Context: {CONTEXT}
Question: {QUERY}
Answer: `;
const client = createClient(SUPABASE_URL, SUPABASE_API_KEY);
const query = (vector: number[]) => supabase.query({ client, namespace, vector });
const handler = getCompletionHandler({ OPENAI_API_KEY, query, system, prompt });
export default function (req: Request) {
return handler(req);
}
See github.com/7-docs for more examples, starter kits, etc.
To query the content from the CLI, use @7-docs/cli.
FAQs
Dependency-free package for 7-docs to query your content from anywhere JavaScript can run
The npm package @7-docs/edge receives a total of 33 weekly downloads. As such, @7-docs/edge popularity was classified as not popular.
We found that @7-docs/edge demonstrated a not healthy version release cadence and project activity because the last version was released 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.
Security News
CVEForecast.org uses machine learning to project a record-breaking surge in vulnerability disclosures in 2025.
Security News
Browserslist-rs now uses static data to reduce binary size by over 1MB, improving memory use and performance for Rust-based frontend tools.
Research
Security News
Eight new malicious Firefox extensions impersonate games, steal OAuth tokens, hijack sessions, and exploit browser permissions to spy on users.