आपका ब्राउज़र
जाँच हो रही है…
किसी असली एजेंट को जोड़ने के लिए हाल का Chrome इस्तेमाल करें और chrome://flags में "WebMCP for testing" फ़्लैग ऑन करें।
AI एजेंट्स
WebMCP एक नया ब्राउज़र स्टैंडर्ड है। वेब पेज बताता है कि वह क्या-क्या कर सकता है, टूल्स के रूप में, जिनमें हर एक का नाम, विवरण और JSON इनपुट स्कीमा होता है। फिर ब्राउज़र में मौजूद AI एजेंट यह अंदाज़ा लगाने के बजाय कि कहाँ क्लिक करना है, इन्हीं टूल्स के ज़रिए साइट का इस्तेमाल करता है।
जाँच हो रही है…
किसी असली एजेंट को जोड़ने के लिए हाल का Chrome इस्तेमाल करें और chrome://flags में "WebMCP for testing" फ़्लैग ऑन करें।
पेज टूल्स घोषित करता है
हर फ़ीचर अपने टूल्स Angular में रजिस्टर करता है। माइनस्वीपर के टूल्स तभी मौजूद रहते हैं, जब गेम स्क्रीन पर हो।
ब्राउज़र उन्हें लिस्ट करता है
ब्राउज़र एजेंट को खुले पेज के टूल्स दिखाता है: नाम, विवरण और इनपुट स्कीमा।
एजेंट टूल को कॉल करता है
टूल वही Angular सर्विस कॉल करता है जो बटन करते हैं, इसलिए पेज ऐसे अपडेट होता है जैसे किसी इंसान ने क्लिक किया हो।
किसी टूल को वैसे ही कॉल करें जैसे एजेंट करता। दाईं ओर का गेम लाइव है, इसलिए उसके टूल्स भी इस पेज पर एक्टिव हैं।
कठिनाई
इस साइट पर हर टूल कॉल, चाहे AI एजेंट से हो या प्लेग्राउंड से। JSON देखने के लिए किसी पंक्ति को खोलें।
वे सभी टूल्स जो यह वेबसाइट उपलब्ध करा सकती है, और वे कहाँ उपलब्ध हैं।
list_pages अभी एक्टिव सिर्फ़ पढ़ने के लिएLists the pages of this website, the article ids, the supported languages and the page that is open now.
कोई इनपुट नहीं
navigate_to_page अभी एक्टिव Opens a page of this website in the current language. For a specific article pass page "articles" and its article id.
{
"type": "object",
"properties": {
"page": {
"type": "string",
"enum": [
"home",
"games",
"minesweeper",
"chess",
"mill",
"abalone",
"articles",
"joker",
"webmcp",
"contact",
"links"
],
"description": "Page to open."
},
"article": {
"type": "string",
"enum": [
"resource-sandbox",
"birds",
"r2r-vs-ros2"
],
"description": "Optional article id, only with page \"articles\"."
}
},
"required": [
"page"
]
}set_language अभी एक्टिव Switches the website language and keeps the current page open.
{
"type": "object",
"properties": {
"language": {
"type": "string",
"enum": [
"pl",
"en",
"de",
"fr",
"es",
"it",
"pt",
"uk",
"no",
"sv",
"zh",
"ja",
"hi"
],
"description": "pl=Polish, en=English, de=German, fr=French, es=Spanish, it=Italian, pt=Portuguese (Brazil), uk=Ukrainian, no=Norwegian, sv=Swedish, zh=Chinese, ja=Japanese, hi=Hindi."
}
},
"required": [
"language"
]
}set_color_scheme अभी एक्टिव Switches the website between the light and the dark color scheme.
{
"type": "object",
"properties": {
"scheme": {
"type": "string",
"enum": [
"light",
"dark"
]
}
},
"required": [
"scheme"
]
}set_seasonal_effect अभी एक्टिव Sets the decorative animated overlay. "auto" picks one by date: snow in winter, butterflies in spring, halloween in October.
{
"type": "object",
"properties": {
"effect": {
"type": "string",
"enum": [
"auto",
"off",
"snow",
"butterflies",
"halloween"
]
}
},
"required": [
"effect"
]
}minesweeper_get_board अभी एक्टिव सिर्फ़ पढ़ने के लिएReturns the visible board, the game status and the counters. Hidden cells never reveal whether they hold a mine.
कोई इनपुट नहीं
minesweeper_reveal_cell अभी एक्टिव Reveals a hidden cell, like a left click. Revealing a mine loses the game. Returns the updated board.
{
"type": "object",
"properties": {
"row": {
"type": "integer",
"minimum": 0,
"maximum": 23,
"description": "0-based row, top to bottom."
},
"col": {
"type": "integer",
"minimum": 0,
"maximum": 29,
"description": "0-based column, left to right."
}
},
"required": [
"row",
"col"
]
}minesweeper_toggle_flag अभी एक्टिव Toggles a flag on a hidden cell, like a right click. Returns the updated board.
{
"type": "object",
"properties": {
"row": {
"type": "integer",
"minimum": 0,
"maximum": 23,
"description": "0-based row, top to bottom."
},
"col": {
"type": "integer",
"minimum": 0,
"maximum": 29,
"description": "0-based column, left to right."
}
},
"required": [
"row",
"col"
]
}minesweeper_new_game अभी एक्टिव असर डालने वालाDiscards the current game and starts a new one. Optionally switches the difficulty: beginner (9×9, 10 mines), intermediate (16×16, 40 mines), expert (16 rows × 30 columns, 99 mines) or custom (the last custom size).
{
"type": "object",
"properties": {
"difficulty": {
"type": "string",
"enum": [
"beginner",
"intermediate",
"expert",
"custom"
]
}
}
}ask_joke_botअविश्वसनीय आउटपुटSends a message to the AI joke bot on this page. The message and the answer appear in the chat. Returns the joke.
{
"type": "object",
"properties": {
"topic": {
"type": "string",
"description": "Topic or message for the joke bot."
}
},
"required": [
"topic"
]
}टूल्स साधारण constants हैं, जो Angular सर्विसेज़ को कॉल करते हैं। रजिस्ट्रेशन उन्हें ऐप या किसी कंपोनेंट के लाइफ़टाइम से जोड़ता है।
टूल डिफ़ाइन करें
export const SET_COLOR_SCHEME = defineWebMcpTool({
name: 'set_color_scheme',
description: 'Switches the website between the light and the dark color scheme.',
inputSchema: {
type: 'object',
properties: { scheme: { type: 'string', enum: ['light', 'dark'] } },
required: ['scheme'],
},
execute: (input) => {
inject(ColorSchemeService).setScheme(input.scheme);
return `Color scheme set to ${input.scheme}.`;
},
});हर पेज के लिए टूल्स रजिस्टर करें
export const appConfig: ApplicationConfig = {
providers: [
provideWebMcpTools('site', SITE_WEBMCP_TOOLS),
],
};एक कंपोनेंट के लिए टूल्स रजिस्टर करें
export class MinesweeperComponent {
constructor() {
declareWebMcpTools('minesweeper', MINESWEEPER_WEBMCP_TOOLS);
}
}DevTools कंसोल में आज़माएँ
const tools = await document.modelContext.getTools();
tools.map((tool) => tool.name);
const reveal = tools.find((tool) => tool.name === 'minesweeper_reveal_cell');
await document.modelContext.executeTool(reveal, { row: 4, col: 4 });