👉 AIは“自分の世界”を構築できる
🔥 ここから始まる。数式が世界を侵食するAIエコシステム爆誕 🔥
ねえ、ちょっと想像してみてほしい。
「幸せって何?」
「やる気ってどこから来る?」
「人間関係って、どうして壊れる?」
普通のAIはこういう問いに“言葉”で答える。
でも——このシステムは違う。
👉 すべてを“数式”で答える。
🧪 数式マニアAI、覚醒。
このアプリは、ただのチャットボットじゃない。
むしろ逆だ。
👉 意味を理解することを放棄し、すべてを計算に叩き込むAI。
しかもやばいのはここから👇
🏭 MCPサーバーを“無限に生成”するAI
スタートボタンを押すと何が起きるか?

💥 ツールが増殖し始める。
幸福度を計算する関数
恋愛の崩壊を表す指数関数
やる気を導く謎の式
人間関係を表す意味不明な比率
👉 それらがすべて JSONとして蓄積される。
👉 そして必要なときに 実際に呼び出されて実行される。
⚙️ つまりこれは何か?
これはもう一言で言うと:
👉 “AIがツールを生み、AIがツールを使う世界”
🧠 まるで巨大なエコシステム
この構造、どこかで見覚えありませんか?

そう。
巨大なソフトウェア群が連携し、
一つの文明のように機能するあの構造。
🚀 模倣しているもの
このプロジェクトの本質はここにある。
👉 巨大AIエコシステムの“ミニチュア再現”
無数のモジュール(MCPサーバー)
統一されたインターフェース(JSON)
必要に応じた動的呼び出し
継続的な自己拡張
ただし違う点がひとつある。
🤯 決定的に違うところ
👉 全部、狂っている。
数式は適当
意味は無視
でも動く
そして“それっぽい”
💬 実際の挙動
ユーザー:
「最近ちょっと元気ないんだよね…」
AI:
🧪 計算開始…
📐 式:
motivation = dopamine * novelty / fatigue
📊 結果:
0.42
👉 「あなたのやる気は低下しています」
……いや、なんか納得してしまうのが怖い。
🔁 無限増殖モード
このアプリの最大の中毒性。

▶️ スタートを押すと:
新しいツール生成
JSONに追加
UIに出現
また生成
また追加
👉 止まらない。
👉 世界が数式で埋まっていく。
🌌 これは何を意味しているのか?
このプロジェクトはただのジョークではない。
むしろ逆だ。
👉 AIの未来の一断面を、極端な形で見せている。
👉 AIは“自分の世界”を構築できる
😏 最後に
スタートボタンを押してみてください。
きっとこう思うはずです。
👉 「あれ、これ…止めなくていいのか?」
🧪 数式は、すべてを支配する。
<!DOCTYPE html>
<html lang="ja">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>🧪 数式マニアMCP生成AI</title>
<style>
*{margin:0;padding:0;box-sizing:border-box;}
body{
background: radial-gradient(circle at top,#0f2027,#0a0a0a 70%);
color:#eaffea;
font-family: system-ui, monospace;
padding:20px;
min-height:100vh;
}
/* コンテナ */
.container{
max-width:1000px;
margin:auto;
}
/* タイトル */
h1{
text-align:center;
margin-bottom:20px;
font-size:2rem;
background: linear-gradient(90deg,#00ffcc,#66ffcc);
-webkit-background-clip:text;
-webkit-text-fill-color:transparent;
}
/* ステータス */
#statusIndicator{
text-align:center;
padding:10px;
margin-bottom:20px;
border-radius:10px;
background:rgba(0,255,204,0.05);
border:1px solid rgba(0,255,204,0.2);
}
/* ボタン */
.controls{
text-align:center;
margin-bottom:20px;
}
button{
padding:12px 18px;
margin:5px;
border-radius:10px;
border:1px solid rgba(0,255,204,0.3);
background:rgba(0,255,204,0.05);
color:#00ffcc;
cursor:pointer;
backdrop-filter: blur(10px);
transition:all .3s ease;
}
button:hover{
transform:translateY(-2px);
box-shadow:0 0 15px rgba(0,255,204,0.4);
}
/* ログ */
.log-container{
background:rgba(0,0,0,0.5);
border-radius:15px;
padding:15px;
height:260px;
overflow:auto;
margin:20px 0;
border:1px solid rgba(0,255,204,0.2);
backdrop-filter: blur(12px);
}
/* 入力 */
.input-section{
display:flex;
gap:10px;
margin-bottom:20px;
}
input{
flex:1;
padding:12px;
border-radius:10px;
border:1px solid rgba(0,255,204,0.2);
background:rgba(0,0,0,0.5);
color:#fff;
}
/* ツール */
.tools-header{
display:flex;
justify-content:space-between;
margin-bottom:10px;
}
#tools-count{
background:#00ffcc;
color:#000;
padding:3px 10px;
border-radius:20px;
}
/* グリッド */
.tools-grid{
display:grid;
grid-template-columns:repeat(auto-fill,minmax(280px,1fr));
gap:15px;
}
/* カード */
.tool-card{
background:rgba(0,255,204,0.05);
border:1px solid rgba(0,255,204,0.2);
border-radius:14px;
padding:15px;
transition:all .3s ease;
position:relative;
overflow:hidden;
}
.tool-card::before{
content:"";
position:absolute;
top:0;
left:-100%;
width:100%;
height:2px;
background:linear-gradient(90deg,transparent,#00ffcc,transparent);
animation:scan 3s infinite;
}
@keyframes scan{
0%{left:-100%;}
100%{left:100%;}
}
.tool-card:hover{
transform:translateY(-5px) scale(1.02);
box-shadow:0 10px 25px rgba(0,255,204,0.2);
}
/* 数式 */
.tool-formula{
font-family:monospace;
background:rgba(0,0,0,0.4);
padding:8px;
border-radius:6px;
margin:10px 0;
}
/* ボタン */
.tool-actions{
display:flex;
gap:5px;
}
.tool-actions button{
flex:1;
padding:6px;
font-size:.8rem;
}
</style>
</head>
<body>
<div class="container">
<h1>🧠 狂った数式マニアAI</h1>
<div id="statusIndicator">🔴 停止中</div>
<div class="controls">
<button onclick="startGeneration()">▶️ スタート</button>
<button onclick="stopGeneration()">⏹ ストップ</button>
<button onclick="quickGenerate()">⚡ 生成</button>
</div>
<div class="log-container" id="log"></div>
<div class="input-section">
<input id="userInput" placeholder="話しかける...">
<button onclick="sendMessage()">送信</button>
</div>
<div class="tools-header">
<h3>ツール</h3>
<span id="tools-count">0</span>
</div>
<div id="tools" class="tools-grid"></div>
</div>
<script>
const API_URL="http://localhost:1234/v1/chat/completions";
let running=false;
let tools=[];
const logDiv=document.getElementById("log");
const toolsDiv=document.getElementById("tools");
const toolsCount=document.getElementById("tools-count");
const statusIndicator=document.getElementById("statusIndicator");
function log(msg){
const d=document.createElement("div");
d.textContent=msg;
logDiv.appendChild(d);
logDiv.scrollTop=logDiv.scrollHeight;
}
async function callLLM(prompt){
try{
const res=await fetch(API_URL,{
method:"POST",
headers:{"Content-Type":"application/json"},
body:JSON.stringify({
model:"local-model",
messages:[{role:"user",content:prompt}]
})
});
const data=await res.json();
return data.choices[0].message.content;
}catch{
log("❌ APIエラー");
return null;
}
}
async function generateTool(){
const prompt=`
狂った数学ツールをJSONで出力:
{
"name":"名前",
"formula":"数式",
"code":"function(a,b,c){return ...}",
"description":"説明"
}`;
const res=await callLLM(prompt);
if(!res)return;
try{
let t=res.trim()
.replace(/```json/g,"")
.replace(/```/g,"")
.replace(/\r?\n/g,"");
const match=t.match(/\{.*\}/);
if(!match)throw"err";
const tool=JSON.parse(match[0]);
tools.push(tool);
renderTools();
log("✨ "+tool.name);
}catch{
log("⚠️ パース失敗");
}
}
function renderTools(){
toolsDiv.innerHTML="";
tools.forEach((t,i)=>{
const div=document.createElement("div");
div.className="tool-card";
div.innerHTML=`
<b>${t.name}</b>
<div class="tool-formula">${t.formula}</div>
<div>${t.description}</div>
<div class="tool-actions">
<button onclick="executeTool(${i})">実行</button>
<button onclick="deleteTool(${i})">削除</button>
</div>
`;
toolsDiv.appendChild(div);
});
toolsCount.textContent=tools.length;
}
function safeExecute(code,a=1,b=2,c=3){
try{
return new Function("return "+code)()(a,b,c);
}catch{
return "ERROR";
}
}
function executeTool(i){
const r=safeExecute(tools[i].code);
log("⚡ "+tools[i].name+" → "+r);
}
function deleteTool(i){
tools.splice(i,1);
renderTools();
}
async function startGeneration(){
running=true;
statusIndicator.textContent="🟢 実行中";
while(running){
await generateTool();
await new Promise(r=>setTimeout(r,1500));
}
}
function stopGeneration(){
running=false;
statusIndicator.textContent="🔴 停止中";
}
function quickGenerate(){
generateTool();
}
async function sendMessage(){
const input=document.getElementById("userInput");
const msg=input.value;
input.value="";
log("👤 "+msg);
const res=await callLLM(msg);
if(res)log("🤖 "+res);
}
</script>
</body>
</html>