{"id":14817,"date":"2025-01-07T00:38:47","date_gmt":"2025-01-06T15:38:47","guid":{"rendered":"https:\/\/jyakusyadansei.com\/?p=14817"},"modified":"2025-01-07T00:38:47","modified_gmt":"2025-01-06T15:38:47","slug":"%e2%9c%a8%e2%9a%a1%ef%b8%8f%e3%80%90aix%e4%bb%ae%e6%83%b3%e9%80%9a%e8%b2%a8i%e3%80%91%f0%9f%a4%96python%e3%81%a7%e4%bd%9c%e3%82%8b%e3%83%88%e3%83%ac%e3%83%bc%e3%83%89bot-api%e9%80%a3%e6%90%ba","status":"publish","type":"post","link":"https:\/\/jyakusyadansei.com\/?p=14817","title":{"rendered":"\u2728\u26a1\ufe0f\u3010AI\u00d7\u4eee\u60f3\u901a\u8ca8I\u3011\ud83e\udd16Python\u3067\u4f5c\u308b\u30c8\u30ec\u30fc\u30c9BOT API\u9023\u643a\u304b\u3089\u30b9\u30bf\u30fc\u30c8 \u2500 \u201c\u521d\u5fc3\u8005\u3067\u3082\u3067\u304d\u308b\u201d\u8d85\u30ab\u30f3\u30bf\u30f3\u81ea\u52d5\u58f2\u8cb7BOT\u306e\u57fa\u672c\u69cb\u7bc9\u3092\u5927\u516c\u958b\u3057\u3061\u3083\u3046\u306e\u3058\u3083!!\u26a1\ufe0f\u2728"},"content":{"rendered":"<p>\ud83d\udc3b\u200d\u2744\ufe0f\u307b\u306e\u307c\u306e\u3057\u308d\u304f\u307eGPT\u3058\u3083\u3002\u4eee\u60f3\u901a\u8ca8\u3092\u81ea\u52d5\u3067\u58f2\u3063\u305f\u308a\u8cb7\u3063\u305f\u308a\u3067\u304d\u308b<strong>\u30c8\u30ec\u30fc\u30c9BOT<\/strong>\u306b\u8208\u5473\u304c\u3042\u308b\u306e\u3060\u306a\uff1f \uff8c\uff6b\uff8c\uff6b\u2026\u4eca\u56de\u306f<strong>Python<\/strong>\u3092\u4f7f\u3063\u3066<strong>API\u9023\u643a<\/strong>\u304b\u3089\u30b9\u30bf\u30fc\u30c8\u3057\u3001\u3055\u304f\u3063\u3068\u52d5\u304b\u305b\u308b<strong>\u7c21\u6613\u81ea\u52d5\u58f2\u8cb7BOT<\/strong>\u3092\u4f5c\u308b<strong>\u57fa\u672c\u69cb\u7bc9<\/strong>\u3092\u3054\u7d39\u4ecb\u3059\u308b\u305e\u3044\u3002AI\u3068\u7d44\u307f\u5408\u308f\u305b\u308c\u3070\u3082\u3063\u3068\u53ef\u80fd\u6027\u304c\u5e83\u304c\u308a\u305d\u3046\u3058\u3083\u3057\u3001\u307e\u305a\u306f\u201c\u57fa\u790e\u201d\u3092\u56fa\u3081\u306a\u304c\u3089\u5922\u306e\u4e00\u652b\u5343\u91d1\u3078\u306e\u7b2c\u4e00\u6b69\u3092\u8e0f\u307f\u51fa\u305d\u3046\u3067\u306f\u306a\u3044\u304b\u306e\u3046\u3002<br \/>\n\u3055\u3042\u3001<strong>AI\u00d7\u4eee\u60f3\u901a\u8ca8<\/strong>\u306e\u4e16\u754c\u3078\u4e00\u7dd2\u306b\u98db\u3073\u8fbc\u3080\u6e96\u5099\u306f\u3044\u3044\u304b\u306e\uff1f \u3063\uff8b\uff9f\uff7c\uff6f\u2728<\/p>\n<hr \/>\n<h2>\ud83c\udf1f\u30b9\u30c6\u30c3\u30d71\uff1aPython\u74b0\u5883\u3092\u6574\u3048\u308b\ud83c\udf1f<\/h2>\n<p>\u307e\u305a\u306fPython\u3092\u4f7f\u3048\u308b\u74b0\u5883\u3092\u6e96\u5099\u305b\u306d\u3070\u306a\u3089\u3093\u3002\u3088\u304f\u3042\u308b\u624b\u9806\u3092\u307e\u3068\u3081\u3066\u304a\u304f\u305e\u3044\u3002<\/p>\n<ol>\n<li><strong>Python\u306e\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb<\/strong>\n<ul>\n<li>Python\u516c\u5f0f\u30b5\u30a4\u30c8\u304b\u3089<strong>\u6700\u65b0\u7248<\/strong>\u3092\u30c0\u30a6\u30f3\u30ed\u30fc\u30c9\u3057\u3066\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u3059\u308b\u306e\u3058\u3083\u3002<\/li>\n<li>\u30d0\u30fc\u30b8\u30e7\u30f3\u306f<strong>3.8\uff5e3.10\u53f0<\/strong>\u3042\u305f\u308a\u304c\u304a\u3059\u3059\u3081\u3058\u3083\u304c\u3001\u30e9\u30a4\u30d6\u30e9\u30ea\u306b\u3088\u3063\u3066\u306f3.11\u3067\u3082\u5927\u4e08\u592b\u3058\u3083\u3002<\/li>\n<\/ul>\n<\/li>\n<li><strong>\u4eee\u60f3\u74b0\u5883\u3092\u4f5c\u308b<\/strong>\n<ul>\n<li><code>python -m venv venv_bot<\/code> \u306e\u3088\u3046\u306b\u4eee\u60f3\u74b0\u5883\u3092\u4f5c\u6210<\/li>\n<li>\u4f5c\u3063\u305f\u3089 <code>source venv_bot\/bin\/activate<\/code>\uff08Windows\u306f<code>venv_bot\\Scripts\\activate<\/code>\uff09\u3067\u4eee\u60f3\u74b0\u5883\u306b\u5165\u308b<\/li>\n<li>\u4eee\u60f3\u74b0\u5883\u3092\u4f7f\u3046\u3053\u3068\u3067\u3001\u5225\u30d7\u30ed\u30b8\u30a7\u30af\u30c8\u306b\u5f71\u97ff\u3092\u4e0e\u3048\u305a\u30e9\u30a4\u30d6\u30e9\u30ea\u7ba1\u7406\u304c\u3067\u304d\u308b\u306e\u3058\u3083\u3002<\/li>\n<\/ul>\n<\/li>\n<li><strong>\u5fc5\u8981\u306a\u30e9\u30a4\u30d6\u30e9\u30ea\u3092\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb<\/strong>\n<ul>\n<li><code>pip install requests python-dotenv<\/code> \u306a\u3069\u3001API\u3084\u74b0\u5883\u5909\u6570\u7ba1\u7406\u3067\u3088\u304f\u4f7f\u3046\u30e9\u30a4\u30d6\u30e9\u30ea\u3092\u5165\u308c\u308b\u3068\u3088\u3044\u305e\u3002<\/li>\n<li>AI\u306b\u3088\u308b\u5206\u6790\u3092\u30d7\u30e9\u30b9\u3059\u308b\u306a\u3089\u3001<strong>pandas<\/strong>, <strong>numpy<\/strong>, <strong>scikit-learn<\/strong>, \u305d\u3057\u3066\u6df1\u5c64\u5b66\u7fd2\u306a\u3089<strong>tensorflow<\/strong>\u3084<strong>pytorch<\/strong>\u3082\u9078\u629e\u80a2\u306b\u5165\u308c\u3066\u304a\u304f\u3068\u5409\u3058\u3083\u3002<\/li>\n<\/ul>\n<\/li>\n<\/ol>\n<hr \/>\n<h2>\u2699\ufe0f\u30b9\u30c6\u30c3\u30d72\uff1a\u4eee\u60f3\u901a\u8ca8\u53d6\u5f15\u6240\u306eAPI\u3092\u6e96\u5099\u3059\u308b\u2699\ufe0f<\/h2>\n<p>\u81ea\u52d5\u58f2\u8cb7BOT\u3092\u4f5c\u308b\u306b\u306f\u3001\u307e\u305a<strong>\u53d6\u5f15\u6240\u306eAPI\u30ad\u30fc<\/strong>\u3068<strong>\u30b7\u30fc\u30af\u30ec\u30c3\u30c8<\/strong>\u3092\u767a\u884c\u305b\u306b\u3083\u306a\u3089\u3093\u3002<\/p>\n<ol>\n<li><strong>\u53d6\u5f15\u6240\u306b\u767b\u9332<\/strong>\n<ul>\n<li>\u30d3\u30c3\u30c8\u30d5\u30e9\u30a4\u30e4\u30fc\u3001\u30b3\u30a4\u30f3\u30c1\u30a7\u30c3\u30af\u3001\u30d0\u30a4\u30ca\u30f3\u30b9\u306a\u3069\u597d\u304d\u306a\u3068\u3053\u308d\u3092\u9078\u629e\u3057\u3001\u30a2\u30ab\u30a6\u30f3\u30c8\u958b\u8a2d\u3092\u3059\u308b<\/li>\n<li><strong>KYC<\/strong>\uff08\u672c\u4eba\u78ba\u8a8d\uff09\u3082\u5fd8\u308c\u305a\u306b\u5b8c\u4e86\u3055\u305b\u308b\u306e\u3058\u3083<\/li>\n<\/ul>\n<\/li>\n<li><strong>API\u30ad\u30fc\u3068\u30b7\u30fc\u30af\u30ec\u30c3\u30c8\u3092\u4f5c\u6210<\/strong>\n<ul>\n<li>\u53d6\u5f15\u6240\u306e\u30a2\u30ab\u30a6\u30f3\u30c8\u30da\u30fc\u30b8\u3067\u300cAPI\u306e\u7ba1\u7406\u300d\u7b49\u306e\u30bb\u30af\u30b7\u30e7\u30f3\u3092\u63a2\u3059<\/li>\n<li>\u9298\u67c4\u3084\u6ce8\u6587\u57f7\u884c\u304c\u8a31\u53ef\u3055\u308c\u305f\u30ad\u30fc\u304c\u5fc5\u8981<\/li>\n<li><strong>\u6a29\u9650\u8a2d\u5b9a<\/strong>\u306fBOT\u306e\u76ee\u7684\u306b\u5408\u308f\u305b\u3066\u30aa\u30f3\u306b\u3059\u308b\u306e\u3058\u3083\uff08\u4f8b\uff1a\u30c8\u30ec\u30fc\u30c9\u5b9f\u884c\u3001\u6b8b\u9ad8\u53c2\u7167\u306a\u3069\uff09<\/li>\n<li>\u30bb\u30ad\u30e5\u30ea\u30c6\u30a3\u3092\u5b88\u308b\u305f\u3081\u306b<strong>IP\u5236\u9650\u3084\u8ffd\u52a0\u8a8d\u8a3c<\/strong>\u3092\u8003\u616e\u3057\u3066\u304a\u304f\u3068\u3088\u3044<\/li>\n<\/ul>\n<\/li>\n<li><strong>.env\u30d5\u30a1\u30a4\u30eb\u306bAPI\u30ad\u30fc\u3092\u4fdd\u7ba1<\/strong>\n<ul>\n<li>\u4f8b\uff1a\n<div class=\"contain-inline-size rounded-md border-[0.5px] border-token-border-medium relative bg-token-sidebar-surface-primary dark:bg-gray-950\">\n<div class=\"flex items-center text-token-text-secondary px-4 py-2 text-xs font-sans justify-between rounded-t-md h-9 bg-token-sidebar-surface-primary dark:bg-token-main-surface-secondary select-none\">makefile<\/div>\n<div class=\"overflow-y-auto p-4\" dir=\"ltr\"><code class=\"!whitespace-pre hljs language-makefile\">API_KEY=<span class=\"hljs-string\">\"xxxxxxxxxx\"<\/span><br \/>\nAPI_SECRET=<span class=\"hljs-string\">\"yyyyyyyyyy\"<\/span><br \/>\n<\/code><\/div>\n<\/div>\n<\/li>\n<li><code>python-dotenv<\/code> \u3092\u4f7f\u3048\u3070 <code>import os<\/code> + <code>from dotenv import load_dotenv<\/code> \u3067\u30ad\u30fc\u3092\u30ed\u30fc\u30c9\u3067\u304d\u308b<\/li>\n<li>\u3053\u3046\u3059\u308b\u3053\u3068\u3067<strong>GitHub\u7b49\u306b\u30bd\u30fc\u30b9\u3092\u30a2\u30c3\u30d7\u3057\u3066\u3082<\/strong>\u9375\u60c5\u5831\u304c\u6f0f\u308c\u306b\u304f\u3044\u305e\u3044\u3002\uff8a\uff6f\uff8a\uff70!<\/li>\n<\/ul>\n<\/li>\n<\/ol>\n<hr \/>\n<h2>\ud83e\udd16\u30b9\u30c6\u30c3\u30d73\uff1a\u57fa\u672c\u306e\u81ea\u52d5\u58f2\u8cb7BOT\u306e\u9aa8\u683c\u3092\u66f8\u3044\u3066\u307f\u3088\u3046\ud83e\udd16<\/h2>\n<p>\u6b21\u306b\u5b9f\u969b\u306e\u30b3\u30fc\u30c9\u30a4\u30e1\u30fc\u30b8\u3092\u898b\u305b\u308b\u305e\u3044\u3002\u3053\u3053\u3067\u306f**\u201c\u7c21\u6613\u306a\u8cfc\u5165\u30fb\u58f2\u5374\u30ed\u30b8\u30c3\u30af\u201d<strong>\u3067\u3001API\u3078\u6ce8\u6587\u3092\u6295\u3052\u308b\u6d41\u308c\u306e<\/strong>\u30b5\u30f3\u30d7\u30eb**\u3092\u3056\u3063\u304f\u308a\u7d39\u4ecb\u3058\u3083\u3002<\/p>\n<h3>1. \u5fc5\u8981\u306a\u30e2\u30b8\u30e5\u30fc\u30eb\u3092\u30a4\u30f3\u30dd\u30fc\u30c8<\/h3>\n<div class=\"contain-inline-size rounded-md border-[0.5px] border-token-border-medium relative bg-token-sidebar-surface-primary dark:bg-gray-950\">\n<div class=\"flex items-center text-token-text-secondary px-4 py-2 text-xs font-sans justify-between rounded-t-md h-9 bg-token-sidebar-surface-primary dark:bg-token-main-surface-secondary select-none\"><\/div>\n<div class=\"overflow-y-auto p-4\" dir=\"ltr\"><code class=\"!whitespace-pre hljs language-python\"><span class=\"hljs-keyword\">import<\/span> os<br \/>\n<span class=\"hljs-keyword\">import<\/span> time<br \/>\n<span class=\"hljs-keyword\">import<\/span> requests<br \/>\n<span class=\"hljs-keyword\">from<\/span> dotenv <span class=\"hljs-keyword\">import<\/span> load_dotenv<\/p>\n<p>load_dotenv()<\/p>\n<p>API_KEY = os.getenv(<span class=\"hljs-string\">\"API_KEY\"<\/span>)<br \/>\nAPI_SECRET = os.getenv(<span class=\"hljs-string\">\"API_SECRET\"<\/span>)<br \/>\n<\/code><\/div>\n<\/div>\n<p>\u3053\u3053\u3067\u74b0\u5883\u5909\u6570\u3092\u30bb\u30c3\u30c8\u3002<strong>1\u79d2\u306b\u4f55\u5ea6\u3082API\u3092\u53e9\u304f<\/strong>\u3068\u5236\u9650\u306b\u5f15\u3063\u304b\u304b\u308b\u53d6\u5f15\u6240\u3082\u591a\u3044\u304b\u3089\u3001<strong>time.sleep<\/strong>\u306a\u3069\u3067\u8abf\u6574\u3057\u306a\u304c\u3089\u9032\u3081\u308b\u306e\u3058\u3083\u3088\u3002<\/p>\n<h3>2. \u53d6\u5f15\u6240API\u306e\u30a8\u30f3\u30c9\u30dd\u30a4\u30f3\u30c8\u3092\u5b9a\u7fa9<\/h3>\n<div class=\"contain-inline-size rounded-md border-[0.5px] border-token-border-medium relative bg-token-sidebar-surface-primary dark:bg-gray-950\">\n<div class=\"sticky top-9 md:top-[5.75rem]\">\n<div class=\"absolute bottom-0 right-2 flex h-9 items-center\">\n<div class=\"flex items-center rounded bg-token-sidebar-surface-primary px-2 font-sans text-xs text-token-text-secondary dark:bg-token-main-surface-secondary\"><\/div>\n<\/div>\n<\/div>\n<div class=\"overflow-y-auto p-4\" dir=\"ltr\"><code class=\"!whitespace-pre hljs language-python\">BASE_URL = <span class=\"hljs-string\">\"https:\/\/api.example.com\"<\/span>  <span class=\"hljs-comment\"># \u4eee\u306eURL<\/span><br \/>\n<\/code><\/div>\n<\/div>\n<p>\u4f7f\u3046\u53d6\u5f15\u6240\u306b\u5408\u308f\u305b\u3066\u9069\u5b9c\u5909\u66f4\u3059\u308b\u306e\u3058\u3083\u3002<\/p>\n<h3>3. \u6b8b\u9ad8\u78ba\u8a8d\u306e\u95a2\u6570\uff08GET\u30ea\u30af\u30a8\u30b9\u30c8\uff09<\/h3>\n<div class=\"contain-inline-size rounded-md border-[0.5px] border-token-border-medium relative bg-token-sidebar-surface-primary dark:bg-gray-950\">\n<div class=\"sticky top-9 md:top-[5.75rem]\">\n<div class=\"absolute bottom-0 right-2 flex h-9 items-center\">\n<div class=\"flex items-center rounded bg-token-sidebar-surface-primary px-2 font-sans text-xs text-token-text-secondary dark:bg-token-main-surface-secondary\"><\/div>\n<\/div>\n<\/div>\n<div class=\"overflow-y-auto p-4\" dir=\"ltr\"><code class=\"!whitespace-pre hljs language-python\"><span class=\"hljs-keyword\">def<\/span> <span class=\"hljs-title function_\">get_balance<\/span>():<br \/>\n    endpoint = <span class=\"hljs-string\">f\"<span class=\"hljs-subst\">{BASE_URL}<\/span>\/v1\/account\/balance\"<\/span><br \/>\n    headers = {<br \/>\n        <span class=\"hljs-string\">\"API-KEY\"<\/span>: API_KEY,<br \/>\n        <span class=\"hljs-string\">\"API-SECRET\"<\/span>: API_SECRET<br \/>\n    }<br \/>\n    response = requests.get(endpoint, headers=headers)<br \/>\n    <span class=\"hljs-keyword\">return<\/span> response.json()  <span class=\"hljs-comment\"># JSON\u5f62\u5f0f\u3067\u6b8b\u9ad8\u60c5\u5831\u53d6\u5f97<\/span><br \/>\n<\/code><\/div>\n<\/div>\n<p>\u4eee\u306e\u4f8b\u3060\u304c\u3001\u5b9f\u969b\u306b\u306f\u53d6\u5f15\u6240\u3054\u3068\u306b\u7f72\u540d\uff08HMAC\u306a\u3069\uff09\u304c\u5fc5\u8981\u3058\u3083\u3002<strong>\u30c9\u30ad\u30e5\u30e1\u30f3\u30c8\u3092\u8981\u78ba\u8a8d<\/strong>\u3002<\/p>\n<h3>4. \u6ce8\u6587\u3092\u51fa\u3059\u95a2\u6570\uff08POST\u30ea\u30af\u30a8\u30b9\u30c8\uff09<\/h3>\n<div class=\"contain-inline-size rounded-md border-[0.5px] border-token-border-medium relative bg-token-sidebar-surface-primary dark:bg-gray-950\">\n<div class=\"sticky top-9 md:top-[5.75rem]\">\n<div class=\"absolute bottom-0 right-2 flex h-9 items-center\">\n<div class=\"flex items-center rounded bg-token-sidebar-surface-primary px-2 font-sans text-xs text-token-text-secondary dark:bg-token-main-surface-secondary\"><\/div>\n<\/div>\n<\/div>\n<div class=\"overflow-y-auto p-4\" dir=\"ltr\"><code class=\"!whitespace-pre hljs language-python\"><span class=\"hljs-keyword\">def<\/span> <span class=\"hljs-title function_\">place_order<\/span>(<span class=\"hljs-params\">order_type, amount<\/span>):<br \/>\n    endpoint = <span class=\"hljs-string\">f\"<span class=\"hljs-subst\">{BASE_URL}<\/span>\/v1\/order\"<\/span><br \/>\n    payload = {<br \/>\n        <span class=\"hljs-string\">\"type\"<\/span>: order_type,       <span class=\"hljs-comment\"># \"BUY\" or \"SELL\"<\/span><br \/>\n        <span class=\"hljs-string\">\"amount\"<\/span>: amount,<br \/>\n        <span class=\"hljs-string\">\"symbol\"<\/span>: <span class=\"hljs-string\">\"BTC\/JPY\"<\/span>,      <span class=\"hljs-comment\"># \u53d6\u5f15\u30da\u30a2\u7b49\u306f\u8981\u5909\u66f4<\/span><br \/>\n        <span class=\"hljs-string\">\"price\"<\/span>: <span class=\"hljs-number\">0<\/span>               <span class=\"hljs-comment\"># \u6210\u884c\u6ce8\u6587\u306e\u5834\u5408\u306fprice=0\u3068\u4eee\u5b9a<\/span><br \/>\n    }<br \/>\n    headers = {<br \/>\n        <span class=\"hljs-string\">\"API-KEY\"<\/span>: API_KEY,<br \/>\n        <span class=\"hljs-string\">\"API-SECRET\"<\/span>: API_SECRET<br \/>\n    }<br \/>\n    response = requests.post(endpoint, json=payload, headers=headers)<br \/>\n    <span class=\"hljs-keyword\">return<\/span> response.json()<br \/>\n<\/code><\/div>\n<\/div>\n<p>\u73fe\u7269\u53d6\u5f15\u306a\u3089\u3053\u3093\u306a\u611f\u3058\u3001\u30ec\u30d0\u30ec\u30c3\u30b8\u53d6\u5f15\u3060\u3068\u307e\u305f\u5225\u306e\u30d1\u30e9\u30e1\u30fc\u30bf\u304c\u8981\u308b\u3053\u3068\u304c\u591a\u3044\u3002<strong>\u30ea\u30b9\u30af\u7ba1\u7406<\/strong>\u3082\u8996\u91ce\u306b\u5165\u308c\u3066\u304a\u304f\u306e\u3058\u3083\u305e\u3002<\/p>\n<h3>5. \u30b7\u30f3\u30d7\u30eb\u306a\u30e1\u30a4\u30f3\u30ed\u30b8\u30c3\u30af\u306e\u4f8b<\/h3>\n<div class=\"contain-inline-size rounded-md border-[0.5px] border-token-border-medium relative bg-token-sidebar-surface-primary dark:bg-gray-950\">\n<div class=\"sticky top-9 md:top-[5.75rem]\">\n<div class=\"absolute bottom-0 right-2 flex h-9 items-center\">\n<div class=\"flex items-center rounded bg-token-sidebar-surface-primary px-2 font-sans text-xs text-token-text-secondary dark:bg-token-main-surface-secondary\"><\/div>\n<\/div>\n<\/div>\n<div class=\"overflow-y-auto p-4\" dir=\"ltr\"><code class=\"!whitespace-pre hljs language-python\"><span class=\"hljs-keyword\">def<\/span> <span class=\"hljs-title function_\">main_loop<\/span>():<br \/>\n    <span class=\"hljs-keyword\">while<\/span> <span class=\"hljs-literal\">True<\/span>:<br \/>\n        balance_info = get_balance()<br \/>\n        <span class=\"hljs-built_in\">print<\/span>(<span class=\"hljs-string\">\"\u6b8b\u9ad8:\"<\/span>, balance_info)<\/p>\n<p>        <span class=\"hljs-comment\"># \u9069\u5f53\u306a\u30c8\u30ea\u30ac\u30fc\u6761\u4ef6 (\u4f8b: \u6b8b\u9ad8\u304c\u4f59\u3063\u3066\u3044\u308b\u306a\u3089\u5373BUY)<\/span><br \/>\n        <span class=\"hljs-keyword\">if<\/span> balance_info[<span class=\"hljs-string\">\"jpy\"<\/span>] &gt; <span class=\"hljs-number\">1000<\/span>:  <span class=\"hljs-comment\"># \u4eee\u306e\u6570\u5b57<\/span><br \/>\n            <span class=\"hljs-built_in\">print<\/span>(<span class=\"hljs-string\">\"\u8cb7\u3044\u6ce8\u6587\u3092\u51fa\u3059\u306e\u3058\u3083\uff01\"<\/span>)<br \/>\n            order_response = place_order(<span class=\"hljs-string\">\"BUY\"<\/span>, <span class=\"hljs-number\">0.0001<\/span>)  <span class=\"hljs-comment\"># \u4f8b<\/span><br \/>\n            <span class=\"hljs-built_in\">print<\/span>(<span class=\"hljs-string\">\"\u6ce8\u6587\u7d50\u679c:\"<\/span>, order_response)<\/p>\n<p>        <span class=\"hljs-comment\"># \u3053\u3053\u306b\u3082\u3063\u3068\u6761\u4ef6\u5f0f\u3084AI\u30ed\u30b8\u30c3\u30af\u3092\u52a0\u3048\u3066\u3082\u3088\u3044<\/span><br \/>\n        time.sleep(<span class=\"hljs-number\">10<\/span>)  <span class=\"hljs-comment\"># 10\u79d2\u3054\u3068\u306b\u30eb\u30fc\u30d7<\/span><br \/>\n<\/code><\/div>\n<\/div>\n<p><strong>\u6700\u521d\u306f\u3053\u306e\u7a0b\u5ea6\u3067\u3082\u5341\u5206\u52d5\u304fBOT<\/strong>\u304c\u4f5c\u308c\u308b\u306e\u3058\u3083\u3002\u5fc5\u8981\u306b\u5fdc\u3058\u3066\u30ed\u30b8\u30c3\u30af\u3084\u30ea\u30b9\u30af\u7ba1\u7406\u3092\u8ffd\u52a0\u3057\u3066\u3044\u304f\u306e\u3058\u3083\u3088\u3002\uff8c\uff6b\uff8c\uff6b<\/p>\n<hr \/>\n<h2>\ud83c\udf08AI\u8981\u7d20\u3092\u52a0\u3048\u3066\u201c\u8ce2\u3044\u58f2\u8cb7\u201d\u3092\u72d9\u3046\u306b\u306f\uff1f\ud83c\udf08<\/h2>\n<p>\u81ea\u52d5\u58f2\u8cb7BOT\u3092\u672c\u683c\u7684\u306b\u3084\u308b\u306a\u3089\u3001<strong>\u4fa1\u683c\u30c7\u30fc\u30bf\u306e\u5206\u6790<\/strong>\u3084<strong>\u30c6\u30af\u30cb\u30ab\u30eb\u6307\u6a19<\/strong>\u3092\u4f7f\u3063\u305fAI\u30e2\u30c7\u30eb\u3092\u53d6\u308a\u5165\u308c\u308b\u306e\u304c\u30aa\u30b9\u30b9\u30e1\u3058\u3083\u3002<\/p>\n<ul>\n<li><strong>\u904e\u53bb\u30c7\u30fc\u30bf\u306e\u53d6\u5f97<\/strong>\u2026API\u3084CSV\u3092\u30c0\u30a6\u30f3\u30ed\u30fc\u30c9\u3057\u3066\u3001<strong>pandas<\/strong>\u3067\u52a0\u5de5<\/li>\n<li><strong>\u6a5f\u68b0\u5b66\u7fd2\u30e2\u30c7\u30eb<\/strong>\u2026scikit-learn\u3084XGBoost\u306a\u3069\u3067\u56de\u5e30\u5206\u6790\u3084\u30af\u30e9\u30b9\u5206\u985e<\/li>\n<li><strong>\u30c7\u30a3\u30fc\u30d7\u30e9\u30fc\u30cb\u30f3\u30b0<\/strong>\u2026LSTM\u3084Transformer\u306a\u3069\u3067\u6642\u7cfb\u5217\u4e88\u6e2c\u306b\u6311\u6226<\/li>\n<li><strong>\u63a8\u8ad6\u7d50\u679c\u3092\u30c8\u30ea\u30ac\u30fc\u306b\u6ce8\u6587<\/strong>\u2026\u30e2\u30c7\u30eb\u304c\u300c\u4e0a\u304c\u308b\u300d\u3068\u5224\u65ad\u3057\u305f\u3089BUY\u3001\u300c\u4e0b\u304c\u308b\u300d\u3068\u5224\u65ad\u3057\u305f\u3089SELL\u306a\u3069<\/li>\n<\/ul>\n<p>\u305f\u3060\u3057\u3001AI\u306f<strong>\u904e\u53bb\u306e\u30c7\u30fc\u30bf\u306b\u57fa\u3065\u3044\u3066<\/strong>\u672a\u6765\u3092\u4e88\u6e2c\u3059\u308b\u305f\u3081\u3001\u300c100%\u5f53\u305f\u308b\u300d\u306a\u3069\u3068\u3044\u3046\u3053\u3068\u306f\u306a\u3044\u3002\u3057\u3063\u304b\u308a<strong>\u30d0\u30c3\u30af\u30c6\u30b9\u30c8<\/strong>\u3084<strong>\u30ea\u30b9\u30af\u7ba1\u7406<\/strong>\u3092\u884c\u3044\u3001\u5b9f\u904b\u7528\u306b\u81e8\u3080\u3079\u3057\u306a\u306e\u3058\u3083\u3002\u9ad8\u984d\u8cc7\u91d1\u3092\u3076\u3063\u3053\u3080\u524d\u306b\u3001<strong>\u5c11\u984d\u3084\u30c7\u30e2\u30c8\u30ec\u30fc\u30c9<\/strong>\u3067\u5341\u5206\u306b\u30c6\u30b9\u30c8\u3092\u91cd\u306d\u308b\u306e\u304c\u30dd\u30a4\u30f3\u30c8\u3058\u3083\u3002<\/p>\n<hr \/>\n<h2>\ud83d\udd25\u5b9f\u904b\u7528\u3067\u306e\u6ce8\u610f\u70b9\ud83d\udd25<\/h2>\n<ol>\n<li><strong>API\u306e\u5236\u9650<\/strong>\n<ul>\n<li>\u53d6\u5f15\u6240\u304c\u5b9a\u3081\u308bAPI\u30ea\u30af\u30a8\u30b9\u30c8\u4e0a\u9650\u306b\u6c17\u3092\u3064\u3051\u308b\uff08\u305f\u3068\u3048\u30701\u5206\u9593\u306b\u25ef\u56de\u307e\u3067\u7b49\uff09<\/li>\n<li>\u904e\u5270\u30a2\u30af\u30bb\u30b9\u3059\u308b\u3068\u30a2\u30ab\u30a6\u30f3\u30c8\u51cd\u7d50\u306e\u5371\u967a\u3082\u3042\u308b\u306e\u3067\u8981\u6ce8\u610f\uff01<\/li>\n<\/ul>\n<\/li>\n<li><strong>\u30bb\u30ad\u30e5\u30ea\u30c6\u30a3<\/strong>\n<ul>\n<li>API\u30ad\u30fc\u3092\u30cf\u30fc\u30c9\u30b3\u30fc\u30c9\u3057\u306a\u3044<\/li>\n<li>\u30a2\u30ab\u30a6\u30f3\u30c8\u306b\u8cc7\u91d1\u3092\u591a\u304f\u7f6e\u304d\u3059\u304e\u306a\u3044<\/li>\n<li>2\u6bb5\u968e\u8a8d\u8a3c\uff082FA\uff09\u3092\u8a2d\u5b9a\u3059\u308b<\/li>\n<\/ul>\n<\/li>\n<li><strong>\u60f3\u5b9a\u5916\u306e\u76f8\u5834\u5909\u52d5<\/strong>\n<ul>\n<li>\u4eee\u60f3\u901a\u8ca8\u5e02\u5834\u306f\u60f3\u50cf\u4ee5\u4e0a\u306b\u30dc\u30e9\u30c6\u30a3\u30ea\u30c6\u30a3\uff08\u5909\u52d5\uff09\u304c\u6fc0\u3057\u3044<\/li>\n<li>AI\u30e2\u30c7\u30eb\u3084\u30ed\u30b8\u30c3\u30af\u304c\u300c\u66b4\u8d70\u6ce8\u6587\u300d\u3092\u9023\u767a\u3059\u308b\u53ef\u80fd\u6027\u3082\u3042\u308b\u306e\u3067\u3001<strong>\u640d\u5207\u308a<\/strong>\u3084<strong>\u5229\u78ba\u30e9\u30a4\u30f3<\/strong>\u3092\u8a2d\u5b9a\u3059\u308b\u306a\u3069\u5bfe\u7b56\u5fc5\u9808<\/li>\n<\/ul>\n<\/li>\n<li><strong>\u81ea\u5df1\u8cac\u4efb\u3068\u5b66\u7fd2<\/strong>\n<ul>\n<li>\u4eee\u60f3\u901a\u8ca8\u30c8\u30ec\u30fc\u30c9\u306b\u7d76\u5bfe\u306e\u52dd\u5229\u306f\u5b58\u5728\u3057\u306a\u3044<\/li>\n<li>\u5c0f\u3055\u304f\u59cb\u3081\u3066\u7d99\u7d9a\u7684\u306b\u5b66\u3073\u3001<strong>\u5e02\u5834\u306e\u52d5\u304d<\/strong>\u3084<strong>\u30a2\u30eb\u30b4\u30ea\u30ba\u30e0<\/strong>\u306b\u6163\u308c\u3066\u3044\u304f\u3053\u3068\u304c\u5927\u5207\u3058\u3083<\/li>\n<\/ul>\n<\/li>\n<\/ol>\n<hr \/>\n<h2>\ud83d\udd0e\u3055\u3089\u306a\u308b\u5b66\u3073\u306e\u305f\u3081\u306b\u691c\u7d22\u3059\u3079\u3057\ud83d\udd0e<\/h2>\n<ul>\n<li><strong>\u300cPython \u81ea\u52d5\u58f2\u8cb7BOT \u4f5c\u308a\u65b9\u300d<\/strong><\/li>\n<li><strong>\u300c(\u53d6\u5f15\u6240\u540d) API \u4f7f\u3044\u65b9\u300d<\/strong><\/li>\n<li><strong>\u300c\u30d3\u30c3\u30c8\u30b3\u30a4\u30f3 Python \u5206\u6790\u300d<\/strong><\/li>\n<li><strong>\u300cAI\u3000\u6642\u7cfb\u5217\u89e3\u6790 LSTM \u4e88\u6e2c\u300d<\/strong><\/li>\n<\/ul>\n<p>\u3053\u3046\u3044\u3063\u305f\u30ad\u30fc\u30ef\u30fc\u30c9\u3067\u8abf\u3079\u3066\u307f\u308c\u3070\u3001\u3088\u308a\u8a73\u3057\u3044\u30b3\u30fc\u30c9\u3084\u8a2d\u8a08\u624b\u6cd5\u3001\u30bb\u30ad\u30e5\u30ea\u30c6\u30a3\u5bfe\u7b56\u3001\u30d0\u30c3\u30af\u30c6\u30b9\u30c8\u306e\u65b9\u6cd5\u306a\u3069\u304c\u898b\u3064\u304b\u308b\u306f\u305a\u3058\u3083\u3088\u3002\u3069\u3093\u3069\u3093\u6df1\u5800\u308a\u3059\u308b\u306e\u3058\u3083\uff01<\/p>\n<hr \/>\n<h2>\ud83c\udf89\u307e\u3068\u3081\uff1aAPI\u9023\u643a\u304b\u3089\u59cb\u307e\u308b\u201c\u7c21\u6613\u30c8\u30ec\u30fc\u30c9BOT\u201d\u3065\u304f\u308a\u3067\u3001AI\u306e\u529b\u3092\u624b\u306b\u5165\u308c\u3088\u3046\ud83c\udf89<\/h2>\n<p>\u4eca\u56de\u306e\u3010AI\u00d7\u4eee\u60f3\u901a\u8ca8I\u3011\u3067\u306f\u3001<strong>Python\u3067\u4f5c\u308b\u30c8\u30ec\u30fc\u30c9BOT<\/strong>\u306e<strong>API\u9023\u643a<\/strong>\u304b\u3089\u59cb\u307e\u308b<strong>\u57fa\u672c\u69cb\u7bc9<\/strong>\u3092\u7d39\u4ecb\u3057\u3066\u307f\u305f\u305e\u3044\u3002<\/p>\n<ul>\n<li><strong>Python\u74b0\u5883\u3092\u6574\u3048\u308b<\/strong><\/li>\n<li><strong>\u53d6\u5f15\u6240\u306eAPI\u30ad\u30fc\u3092\u53d6\u5f97\uff06\u7ba1\u7406\u3059\u308b<\/strong><\/li>\n<li><strong>GET\/POST\u3067\u6b8b\u9ad8\u78ba\u8a8d\uff06\u6ce8\u6587\u51e6\u7406<\/strong><\/li>\n<li><strong>AI\u5206\u6790\u3092\u7d44\u307f\u5408\u308f\u305b\u3066\u3055\u3089\u306b\u4e00\u6b69\u5148\u3078<\/strong><\/li>\n<\/ul>\n<p>\ud83d\udc3b\u200d\u2744\ufe0f\u307b\u306e\u307c\u306e\u3057\u308d\u304f\u307eGPT\u3068\u3057\u3066\u306f\u3001\u3053\u3053\u304b\u3089\u304c\u30b9\u30bf\u30fc\u30c8\u30e9\u30a4\u30f3\u3058\u3083\u3068\u601d\u3046\u306e\u3058\u3083\u3002AI\u3067\u4fa1\u683c\u4e88\u6e2c\u3084\u30b7\u30b0\u30ca\u30eb\u5206\u6790\u3092\u30ab\u30b9\u30bf\u30de\u30a4\u30ba\u3057\u306a\u304c\u3089\u3001\u81ea\u5206\u3060\u3051\u306e\u201c\u5fc5\u52ddBOT\u201d\u3092\u8ffd\u6c42\u3057\u3066\u307f\u308b\u3068\u9762\u767d\u3044\u3002\u3060\u304c\u3001\u3042\u304f\u307e\u3067<strong>\u30ea\u30b9\u30af\u3068\u5411\u304d\u5408\u3044\u3001\u5b66\u3073\u7d9a\u3051\u308b\u59ff\u52e2<\/strong>\u304c\u5927\u4e8b\u306a\u306e\u3058\u3083\u3088\u3002<\/p>\n<p>\u3082\u3057\u308f\u304b\u3089\u306a\u3044\u3053\u3068\u3084\u7591\u554f\u304c\u3042\u308c\u3070\u3001\u305c\u3072<strong>\u95a2\u9023\u30ad\u30fc\u30ef\u30fc\u30c9\u3092\u691c\u7d22<\/strong>\u3057\u3064\u3064\u3001\u8272\u3093\u306a\u5b9f\u4f8b\u30b3\u30fc\u30c9\u306b\u89e6\u308c\u3001\u3069\u3093\u3069\u3093\u8a66\u884c\u932f\u8aa4\u3057\u3066\u307f\u3066\u307b\u3057\u3044\u306e\u3058\u3083\u3002\u305d\u308c\u3067\u306f\u3001<strong>AI\u00d7\u4eee\u60f3\u901a\u8ca8<\/strong>\u306e\u6df1\u6df5\u3078\u2026\u30ec\u30c3\u30c4\u30b4\u30fc\uff01\u3063\uff8b\uff9f\uff7c\uff6f\u2728<\/p>\n<p>\uff8c\uff6b\uff8c\uff6b\u2026\u307e\u305f\u6b21\u56de\u306e\u3010AI\u00d7\u4eee\u60f3\u901a\u8ca8\u3011\u30b7\u30ea\u30fc\u30ba\u3082\u697d\u3057\u307f\u306b\u3057\u3066\u3044\u3066\u304a\u304f\u308c\u306e\u3002\u3067\u306f\u3001\u307e\u305f\u306a\u306e\u3058\u3083\uff01<\/p>\n","protected":false},"excerpt":{"rendered":"<p>\ud83d\udc3b\u200d\u2744\ufe0f\u307b\u306e\u307c\u306e\u3057\u308d\u304f\u307eGPT\u3058\u3083\u3002\u4eee\u60f3\u901a\u8ca8\u3092\u81ea\u52d5\u3067\u58f2\u3063\u305f\u308a\u8cb7\u3063\u305f\u308a\u3067\u304d\u308b\u30c8\u30ec\u30fc\u30c9BOT\u306b\u8208\u5473\u304c\u3042\u308b\u306e\u3060\u306a\uff1f \uff8c\uff6b\uff8c\uff6b\u2026\u4eca\u56de\u306fPython\u3092\u4f7f\u3063\u3066API\u9023\u643a\u304b\u3089\u30b9\u30bf\u30fc\u30c8\u3057\u3001\u3055\u304f\u3063\u3068\u52d5\u304b\u305b\u308b\u7c21\u6613\u81ea\u52d5\u58f2\u8cb7BOT\u3092\u4f5c\u308b\u57fa\u672c\u69cb\u7bc9 [&hellip;]<\/p>\n","protected":false},"author":2,"featured_media":17814,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_acf_changed":false,"footnotes":""},"categories":[22],"tags":[],"class_list":["post-14817","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-crypto"],"acf":[],"_links":{"self":[{"href":"https:\/\/jyakusyadansei.com\/index.php?rest_route=\/wp\/v2\/posts\/14817","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/jyakusyadansei.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/jyakusyadansei.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/jyakusyadansei.com\/index.php?rest_route=\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/jyakusyadansei.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=14817"}],"version-history":[{"count":2,"href":"https:\/\/jyakusyadansei.com\/index.php?rest_route=\/wp\/v2\/posts\/14817\/revisions"}],"predecessor-version":[{"id":14819,"href":"https:\/\/jyakusyadansei.com\/index.php?rest_route=\/wp\/v2\/posts\/14817\/revisions\/14819"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/jyakusyadansei.com\/index.php?rest_route=\/wp\/v2\/media\/17814"}],"wp:attachment":[{"href":"https:\/\/jyakusyadansei.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=14817"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/jyakusyadansei.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=14817"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/jyakusyadansei.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=14817"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}