top of page


Let's try making an AI 1
AI開発ログ:VBAからPythonへの移行
1. 手書きルールにトリガーワードを組み込む
2. 実行用にCSVで人格プロファイルを設定する
3. 人格値(礼儀正しさ、深みなど)をレスポンスロジックに紐付ける
4. ディープラーニングのリソースを統合する
5. ニュートラルなAI開発はここから始まる
ロジックの進化: ハードコーディングされた IF-ELIF 構造から、モジュール化されたアーキテクチャへの移行。
手法: Pythonを使用して、静的なルールベースシステムから高度なニューラルネットワークへと進化させる。
目標: 個別の要件に基づいた、パーソナライズされたAIエージェントの開発
May 303 min read


Data Extraction and SQL using PowerShell
Pythonがインストールされていない環境において、PowerShellを活用して大容量のデータ抽出を行う際、記述が容易な「CSVパイプ処理(Import-Csv)」と、やや煩雑な「OLEDBによるSQL処理」のどちらを採用すべきか、実機検証を交えて徹底比較しました。数千行程度の手軽な処理であれば1行で直感的に記述できるパイプ処理が最適ですが、データ量が数万行から10万行を超える規模になると、全データをオンメモリで処理するパイプ方式ではメモリの大量消費や深刻な速度低下(フルスキャン)を引き起こすリスクがあります。一方で、OLEDBを介してデータベースエンジン側に処理を委任するSQL方式は、コードが冗長でOfficeのビット数(32bit/64bit)に依存する制約があるものの、必要なデータのみを最適化してスマートに取得できるため、劇的な省メモリと高速化を実現できます。本記事では、Excel 2007から最新のOffice 365環境における接続文字列の記述方法や、実務で嵌まりがちな環境依存のエラー対処法まで、データ量に応じた最適な住み分けの目安を
May 273 min read


Notes on handling CSV and Arrays in Python
PythonでのExcel操作にはopenpyxlライブラリを使用し、ファイルを読み込んで操作できることを確認しました。また、辞書型を用いた配列の入力と表示方法を学びました。出先で実ファイルが置けないWeb環境(paiza)では、io.StringIOを用いて文字列にファイルのふりをさせ、疑似的にcsv.readerに渡して実行しました。CSVの読み込み方式には、行ごとに単純なリストにするcsv.readerと、1行目を項目名として各行を項目名付きデータにするcsv.DictReaderの違いがあることを理解しました。自宅のローカル環境で実行した際にはエラーが発生しましたが、これはファイルパス内の「\t」がエスケープシーケンス(タブ文字)と解釈されたことが原因でした。対策として、パスの区切りをスラッシュにするか、文字列の前に「r」を付けて特殊文字扱いを無効化することで、正しくファイルが読み込めるようになりました。
May 212 min read


IF YOU CAN WRITE THE FLOW YOU CAN DO ANYTHING
- Realizing my former boss's words in PowerShell I created a simple analysis script in PowerShell to inspect the contents of data involving character encodings. The motivation was a situation where I needed to verify file contents in a human-readable format, and I took the opportunity to try it out as part of my learning. While the implementation itself was partially generated by AI, I provided the overall flow (the comments in the PowerShell file at the bottom) and the encod
May 173 min read


Operating Excel using Python
Overcoming the Barriers of Environment Setup 1. Objective The primary goal was to use Python to write "Hello" into cell A1 of a specified Excel file. 2. Tools & Libraries Editor: VS Code (Visual Studio Code) Environment: Python 3.12.1 Library: openpyxl (for Excel manipulation) 3. Troubleshooting & Solutions I encountered initial issues with VS Code extension errors and Windows PATH configuration preventing command recognition. Issue 1: Unable to execute pip install. Solution:
May 111 min read


"Is That Really All It Takes?
Pythonを書いて見た結果。
May 102 min read
About Power Automate
It's been ages since my last post. I've reached this point after repeatedly experiencing setbacks and restarts. A lesson learned. Looking back at my blog, it seems I've been neglecting it for about a year. To begin with, I'm slow to realize things. I only realized this again after restarting this project. Here's a summary: 1. Power Automate has two products, and I mistakenly assumed that both could be developed in the same way. a, Power Automate Cloud As the name suggests, th
May 72 min read
bottom of page