nothumanallowed 13.5.39 → 13.5.41
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +1 -1
- package/src/commands/ui.mjs +20 -0
- package/src/constants.mjs +1 -1
- package/src/services/web-ui.mjs +40 -3
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "nothumanallowed",
|
|
3
|
-
"version": "13.5.
|
|
3
|
+
"version": "13.5.41",
|
|
4
4
|
"description": "NotHumanAllowed — 38 AI agents, 80 tools, Studio (visual agentic workflows). Email, calendar, browser automation, screen capture, canvas, cron/heartbeat, Alexandria E2E messaging, GitHub, Notion, Slack, voice chat, free AI (Liara), 28 languages. Zero-dependency CLI.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"bin": {
|
package/src/commands/ui.mjs
CHANGED
|
@@ -3845,6 +3845,26 @@ ${completedHeadings ? `## SECTIONS ALREADY WRITTEN (headings only):\n${completed
|
|
|
3845
3845
|
return;
|
|
3846
3846
|
}
|
|
3847
3847
|
|
|
3848
|
+
// ── Studio: WebCraft — single non-streaming LLM call ────────────────
|
|
3849
|
+
// Used by the WebCraft tab to generate each file without SSE complexity.
|
|
3850
|
+
// POST /api/studio/webcraft { system, user, max_tokens } → { text }
|
|
3851
|
+
if (pathname === '/api/studio/webcraft' && method === 'POST') {
|
|
3852
|
+
const body = await parseBody(req, 131072); // 128KB max
|
|
3853
|
+
if (!body.system || !body.user) {
|
|
3854
|
+
sendJSON(res, 400, { error: 'system and user required' });
|
|
3855
|
+
logRequest(method, pathname, 400, Date.now() - start);
|
|
3856
|
+
return;
|
|
3857
|
+
}
|
|
3858
|
+
try {
|
|
3859
|
+
const result = await callLLM(config, body.system, body.user, { max_tokens: body.max_tokens || 4096 });
|
|
3860
|
+
sendJSON(res, 200, { text: result });
|
|
3861
|
+
} catch (e) {
|
|
3862
|
+
sendJSON(res, 500, { error: e.message });
|
|
3863
|
+
}
|
|
3864
|
+
logRequest(method, pathname, 200, Date.now() - start);
|
|
3865
|
+
return;
|
|
3866
|
+
}
|
|
3867
|
+
|
|
3848
3868
|
// ── Studio: Parliament deliberation (SSE streaming) ──────────────────
|
|
3849
3869
|
// Implements the Legion DeliberationEngine protocol adapted for Studio:
|
|
3850
3870
|
// Round 1 outputs already exist (from normal workflow steps).
|
package/src/constants.mjs
CHANGED
|
@@ -5,7 +5,7 @@ import { fileURLToPath } from 'url';
|
|
|
5
5
|
const __filename = fileURLToPath(import.meta.url);
|
|
6
6
|
const __dirname = path.dirname(__filename);
|
|
7
7
|
|
|
8
|
-
export const VERSION = '13.5.
|
|
8
|
+
export const VERSION = '13.5.41';
|
|
9
9
|
export const BASE_URL = 'https://nothumanallowed.com/cli';
|
|
10
10
|
export const API_BASE = 'https://nothumanallowed.com/api/v1';
|
|
11
11
|
|
package/src/services/web-ui.mjs
CHANGED
|
@@ -3147,6 +3147,7 @@ var I18N = {
|
|
|
3147
3147
|
wc_generate:'Generate Project', wc_generating:'Generating',
|
|
3148
3148
|
wc_download:'Download Archive', wc_describe_first:'Please describe your project first.',
|
|
3149
3149
|
wc_no_files:'Describe your project and click Generate',
|
|
3150
|
+
wc_examples_label:'Examples',
|
|
3150
3151
|
},
|
|
3151
3152
|
it: {
|
|
3152
3153
|
chat:'Chat', studio:'Studio', settings:'Impostazioni', agents:'Agenti',
|
|
@@ -3182,6 +3183,7 @@ var I18N = {
|
|
|
3182
3183
|
wc_generate:'Genera progetto', wc_generating:'Generazione in corso',
|
|
3183
3184
|
wc_download:'Scarica archivio', wc_describe_first:'Descrivi prima il tuo progetto.',
|
|
3184
3185
|
wc_no_files:'Descrivi il progetto e clicca Genera',
|
|
3186
|
+
wc_examples_label:'Esempi',
|
|
3185
3187
|
},
|
|
3186
3188
|
es: {
|
|
3187
3189
|
chat:'Chat', studio:'Studio', settings:'Configuración', agents:'Agentes',
|
|
@@ -3216,6 +3218,7 @@ var I18N = {
|
|
|
3216
3218
|
wc_generate:'Generar proyecto', wc_generating:'Generando',
|
|
3217
3219
|
wc_download:'Descargar archivo', wc_describe_first:'Por favor describe tu proyecto primero.',
|
|
3218
3220
|
wc_no_files:'Describe el proyecto y haz clic en Generar',
|
|
3221
|
+
wc_examples_label:'Ejemplos',
|
|
3219
3222
|
},
|
|
3220
3223
|
fr: {
|
|
3221
3224
|
chat:'Chat', studio:'Studio', settings:'Paramètres', agents:'Agents',
|
|
@@ -3250,6 +3253,7 @@ var I18N = {
|
|
|
3250
3253
|
wc_generate:'G\u00e9n\u00e9rer le projet', wc_generating:'G\u00e9n\u00e9ration en cours',
|
|
3251
3254
|
wc_download:'T\u00e9l\u00e9charger archive', wc_describe_first:'Veuillez d\u00e9crire votre projet.',
|
|
3252
3255
|
wc_no_files:'D\u00e9crivez le projet et cliquez sur G\u00e9n\u00e9rer',
|
|
3256
|
+
wc_examples_label:'Exemples',
|
|
3253
3257
|
},
|
|
3254
3258
|
de: {
|
|
3255
3259
|
chat:'Chat', studio:'Studio', settings:'Einstellungen', agents:'Agenten',
|
|
@@ -3284,6 +3288,7 @@ var I18N = {
|
|
|
3284
3288
|
wc_generate:'Projekt generieren', wc_generating:'Generierung',
|
|
3285
3289
|
wc_download:'Archiv herunterladen', wc_describe_first:'Bitte beschreibe zuerst dein Projekt.',
|
|
3286
3290
|
wc_no_files:'Beschreibe das Projekt und klicke auf Generieren',
|
|
3291
|
+
wc_examples_label:'Beispiele',
|
|
3287
3292
|
},
|
|
3288
3293
|
};
|
|
3289
3294
|
// Fallback to 'en' for unmapped languages
|
|
@@ -6242,13 +6247,30 @@ function renderWebCraft(el) {
|
|
|
6242
6247
|
'</div>';
|
|
6243
6248
|
}).join('');
|
|
6244
6249
|
|
|
6250
|
+
// Example prompts — clicking fills project name + description
|
|
6251
|
+
var wcExamples = [
|
|
6252
|
+
{name:'MySaaS', desc:'SaaS landing page with hero section, pricing table (free/pro/enterprise), feature comparison grid, user registration (name, email, password), login, protected dashboard with sidebar navigation (overview, settings, billing), account settings page, and email verification flow.'},
|
|
6253
|
+
{name:'MyShop', desc:'E-commerce site with homepage showcasing featured products, product catalog with filters (category, price range), product detail page with image gallery, shopping cart with quantity controls, checkout form with address and payment fields, user registration and login, order history page, and admin panel for product management.'},
|
|
6254
|
+
{name:'MyBlog', desc:'Blog and CMS with homepage listing recent articles (title, excerpt, cover image, author, date), article detail page with markdown rendering, category and tag filtering, author profile page, admin panel for writing and publishing posts (rich text editor), user comments with moderation, and RSS feed endpoint.'},
|
|
6255
|
+
{name:'MyPortfolio', desc:'Professional portfolio with animated hero section (name, role, call-to-action), projects showcase grid with lightbox modal, skills section with progress bars, about page with timeline, contact form with SMTP email sending, dark/light mode toggle, and smooth scroll navigation.'},
|
|
6256
|
+
{name:'MyRestaurant', desc:'Restaurant website with hero with background video, menu page organized by category (starters, mains, desserts, drinks) with photos and prices, online booking form (date, time, party size, special requests) with email confirmation, about us page, gallery section, and contact page with embedded map.'},
|
|
6257
|
+
{name:'MyJobBoard', desc:'Job board platform with homepage listing recent job postings (title, company, location, type), job detail page, company profile pages, candidate registration and login, job application form with resume upload, employer dashboard to post and manage listings, saved jobs for candidates, and job search with filters (location, type, salary range).'}
|
|
6258
|
+
];
|
|
6259
|
+
var wcExHtml = '<div style="margin-bottom:12px;flex-shrink:0"><div style="font-size:9px;color:var(--dim);text-transform:uppercase;letter-spacing:.8px;margin-bottom:6px">'+t('wc_examples_label')+'</div><div style="display:flex;gap:6px;flex-wrap:wrap">' +
|
|
6260
|
+
wcExamples.map(function(ex,i){
|
|
6261
|
+
return '<button onclick="wcPickExample('+i+')" style="padding:4px 10px;border-radius:14px;border:1px solid var(--border2);background:var(--bg3);color:var(--dim);font-size:11px;cursor:pointer;white-space:nowrap">'+wcEsc(ex.name)+'</button>';
|
|
6262
|
+
}).join('') +
|
|
6263
|
+
'</div></div>';
|
|
6264
|
+
|
|
6245
6265
|
el.innerHTML =
|
|
6246
6266
|
'<div style="display:flex;flex-direction:column;height:100%;min-height:0;padding:0 4px">' +
|
|
6247
|
-
'<div style="margin-bottom:
|
|
6267
|
+
'<div style="margin-bottom:10px;flex-shrink:0">' +
|
|
6248
6268
|
'<h2 style="font-size:15px;color:var(--green);margin-bottom:4px">🛠 '+t('wc_title')+'</h2>' +
|
|
6249
6269
|
'<p style="font-size:11px;color:var(--dim);line-height:1.5">'+t('wc_subtitle')+'</p>' +
|
|
6250
6270
|
'</div>' +
|
|
6251
6271
|
|
|
6272
|
+
wcExHtml +
|
|
6273
|
+
|
|
6252
6274
|
'<div style="display:flex;gap:14px;align-items:flex-start;flex:1;min-height:0">' +
|
|
6253
6275
|
|
|
6254
6276
|
// LEFT: config panel
|
|
@@ -6304,6 +6326,21 @@ function renderWebCraft(el) {
|
|
|
6304
6326
|
'</div>';
|
|
6305
6327
|
}
|
|
6306
6328
|
|
|
6329
|
+
function wcPickExample(i) {
|
|
6330
|
+
var wcExamplesData = [
|
|
6331
|
+
{name:'MySaaS', desc:'SaaS landing page with hero section, pricing table (free/pro/enterprise), feature comparison grid, user registration (name, email, password), login, protected dashboard with sidebar navigation (overview, settings, billing), account settings page, and email verification flow.'},
|
|
6332
|
+
{name:'MyShop', desc:'E-commerce site with homepage showcasing featured products, product catalog with filters (category, price range), product detail page with image gallery, shopping cart with quantity controls, checkout form with address and payment fields, user registration and login, order history page, and admin panel for product management.'},
|
|
6333
|
+
{name:'MyBlog', desc:'Blog and CMS with homepage listing recent articles (title, excerpt, cover image, author, date), article detail page with markdown rendering, category and tag filtering, author profile page, admin panel for writing and publishing posts (rich text editor), user comments with moderation, and RSS feed endpoint.'},
|
|
6334
|
+
{name:'MyPortfolio', desc:'Professional portfolio with animated hero section (name, role, call-to-action), projects showcase grid with lightbox modal, skills section with progress bars, about page with timeline, contact form with SMTP email sending, dark/light mode toggle, and smooth scroll navigation.'},
|
|
6335
|
+
{name:'MyRestaurant', desc:'Restaurant website with hero with background video, menu page organized by category (starters, mains, desserts, drinks) with photos and prices, online booking form (date, time, party size, special requests) with email confirmation, about us page, gallery section, and contact page with embedded map.'},
|
|
6336
|
+
{name:'MyJobBoard', desc:'Job board platform with homepage listing recent job postings (title, company, location, type), job detail page, company profile pages, candidate registration and login, job application form with resume upload, employer dashboard to post and manage listings, saved jobs for candidates, and job search with filters (location, type, salary range).'}
|
|
6337
|
+
];
|
|
6338
|
+
var ex = wcExamplesData[i];
|
|
6339
|
+
if (!ex) return;
|
|
6340
|
+
wcState.projectName = ex.name;
|
|
6341
|
+
wcState.description = ex.desc;
|
|
6342
|
+
renderWebCraft(document.getElementById('content'));
|
|
6343
|
+
}
|
|
6307
6344
|
function wcUpdateField(i, val) { wcState.authFields[i].label = val; }
|
|
6308
6345
|
function wcUpdateFieldType(i, t) { wcState.authFields[i].type = t; }
|
|
6309
6346
|
function wcToggleRequired(i, v) { wcState.authFields[i].required = v; }
|
|
@@ -6408,10 +6445,10 @@ async function wcGenerate() {
|
|
|
6408
6445
|
}
|
|
6409
6446
|
|
|
6410
6447
|
async function wcCallLLM(sys, user) {
|
|
6411
|
-
var r = await fetch(API + '/studio/
|
|
6448
|
+
var r = await fetch(API + '/api/studio/webcraft', {
|
|
6412
6449
|
method: 'POST',
|
|
6413
6450
|
headers: {'Content-Type':'application/json'},
|
|
6414
|
-
body: JSON.stringify({system: sys, user: user, max_tokens: 4096
|
|
6451
|
+
body: JSON.stringify({system: sys, user: user, max_tokens: 4096})
|
|
6415
6452
|
});
|
|
6416
6453
|
if (!r.ok) throw new Error('LLM error ' + r.status);
|
|
6417
6454
|
var d = await r.json();
|