You can access search results via JSON API by adding format=json
to your query:
https://codesearch.val.run/?q=image&page=9&format=json
For typeahead suggestions, use the /typeahead
endpoint:
https://codesearch.val.run/typeahead?q=image
Returns an array of strings in format "username" or "username/projectName"
Found 6769 results for "image"(733ms)
681const output: CntOut = { content: genContent };
682if (p.cType === "promo_post" || p.cType === "ad_copy") {
683output.suggestions = "Consider pairing with a relevant image or video. Test different calls-to-action (CTAs).";
684} else if (p.cType === "blog_idea") {
685output.suggestions = "Research keywords for the chosen idea. Create a detailed outline before writing.";
768}, Tone: ${
769p.bTone || "Professional"
770}. INSTR: 1. Gen 2-3 diff concepts (icon, wordmark, abstract/combo). 2. Format each (MD): ### Concept Title \\n#### Description: \\n- Visuals, symbolism, fonts (sans/serif), colors. \\n#### AI Image Generation Prompt: \\n- Detailed prompt for AI (DALL-E, etc). Incl: type(vector logo), subj(BN/initials), style(minimalist, flat), elements, colors, bg(white). Ex: "/imagine prompt: vector logo for '${p.bName}', minimalist flat design [Symbol], clean sans-serif, blue (#005C99), gray (#CCCCCC), isolated white bg --style raw --ar 1:1" 3. Separate concepts w/ '---'. 4. (Opt) If simple, attempt basic SVG: \\\`\\\`\\\`svg ... \\\`\\\`\\\`. 5. Output ONLY concepts. No intro/outro.`;
771const userP =
772`Generate 2-3 distinct logo concepts for "${p.bName}" based on the system prompt. Provide descriptions and AI prompts.`;
782sections.forEach(sec => {
783const titleM = sec.match(/### (.*?)\n/);
784const descM = sec.match(/#### Description:\n([\s\S]*?)(?=\n#### AI Image Generation Prompt:|$)/i);
785const promptM = sec.match(/#### AI Image Generation Prompt:\n([\s\S]*?)(?=\n\`\`\`svg|$)/i);
786if (titleM && descM && promptM) {
787concepts.push(`Title: ${titleM[1].trim()}\n\nDescription:\n${descM[1].trim()}`);
893}
894}
895async function runSimAgent(task: TskIn<SimIn>, logFn: LogFn): Promise<TskOut<SimOut>> {
896const { mid, tid, p } = task;
897let paramDesc = "N/A";
900} catch (e) {
901paramDesc = "[Serialization fail]";
902logFn("WARN", "SimAgent", `Failed serialize specParams tid=${tid}`, { err: (e as Error).message }, mid, tid);
903}
904logFn(
905"INFO",
906"SimAgent",
907`Starting sim task tid=${tid}`,
908{ simType: p.simType, paramsP: paramDesc.substring(0, 100) },
919const simContent = await callOpenAI(sysP, userP, mid, tid, logFn);
920if (!simContent) {
921logFn("WARN", "SimAgent", `LLM no content for sim tid=${tid}.`, undefined, mid, tid);
922return { mid, cid: tid, p: { simResult: "" }, e: "AI failed sim." };
923}
929simResult = simContent.substring(0, splitIndex).trim();
930analysis = simContent.substring(splitIndex).replace(/^## Analysis\s*[\r\n]+/mi, "").trim();
931logFn("DEBUG", "SimAgent", `Analysis section found tid=${tid}`, { analysisLen: analysis.length }, mid, tid);
932} else {
933simResult = simContent.trim();
934logFn("DEBUG", "SimAgent", `No analysis section found tid=${tid}`, undefined, mid, tid);
935}
936if (!simResult && analysis) {
937logFn("WARN", "SimAgent", `Sim result empty, analysis found tid=${tid}.`, undefined, mid, tid);
938simResult = "(Simulation produced analysis but no primary result)";
939} else if (!simResult && !analysis) {
940logFn("WARN", "SimAgent", `Sim result & analysis empty tid=${tid}.`, undefined, mid, tid);
941simResult = "(Simulation produced no output)";
942}
944logFn(
945"INFO",
946"SimAgent",
947`Sim task OK tid=${tid}.`,
948{ resLen: output.simResult.length, hasAnalysis: !!output.analysis },
952return { mid, cid: tid, p: output };
953} catch (err: any) {
954logFn("ERROR", "SimAgent", `Sim task fail tid=${tid}.`, { err: err.message }, mid, tid);
955return { mid, cid: tid, p: { simResult: "" }, e: `Simulation run failed: ${err.message}` };
956}
1016break;
1017case "run_simulation":
1018taskOutput = await runSimAgent(taskInput as TskIn<SimIn>, agentLog);
1019break;
1020case "meta_prompt":
17.hero-pattern {
18background-color: #f9fafb;
19background-image: url("data:image/svg+xml,%3Csvg width='52' height='26' viewBox='0 0 52 26' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23bae6fd' fill-opacity='0.4'%3E%3Cpath d='M10 10c0-2.21-1.79-4-4-4-3.314 0-6-2.686-6-6h2c0 2.21 1.79 4 4 4 3.314 0 6 2.686 6 6 0 2.21 1.79 4 4 4 3.314 0 6 2.686 6 6 0 2.21 1.79 4 4 4v2c-3.314 0-6-2.686-6-6 0-2.21-1.79-4-4-4-3.314 0-6-2.686-6-6zm25.464-1.95l8.486 8.486-1.414 1.414-8.486-8.486 1.414-1.414z' /%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
20}
21</style>