﻿<?xml version="1.0" encoding="utf-8"?>
<rss version="2.0">
  <channel>
    <title>Artificial Intelligence Discussions</title>
    <description>Latest discussions happening in the Artificial Intelligence category</description>
    <link>https://www.aboveunity.com</link>
    <item>
      <title>I'm sorry Dave, I'm afraid I can't do that</title>
      <description>&lt;p&gt;A.I. question!&lt;/p&gt;&#xD;
&lt;p&gt;Just want to see what people are using these days, since the whole A.I. thing has become such a thing.&lt;/p&gt;&#xD;
&lt;p&gt;I was never really an A.I. guy, but for work I started using it for simple tasks. I was given a business level claude account which included cli and web ui chat, both of which are nice for quick questions about how certain scrips behave, or what parameters are expected for an API request, yadda yadda, I have also been using Google A.I, for basic web research, for example looking for specifics on some software exploit or public POC. For personal use I've been using claude.ai free chat, for theoretical questions, about EPR/NMR for example, or for comparing/analyzing energy device coil layouts, general EE calculations, things like that, and I've been really impressed.&lt;/p&gt;&#xD;
&lt;p&gt;However, lately claude has been really really limiting chats. Yesterday I asked one question and my limit was maxed out. Google AI is biased beyond belief and won't let me forget, with every question, that free energy devices have been proven false and Google doesn't want me to be deceived, "believe real science", shit like that. Google also seems to stray off path very easy and end up talking about something that is completely not relevant to the original question/conversation.&lt;/p&gt;&#xD;
&lt;p&gt;So I'm looking for alternatives. I've started to give perplexity free a try. Nice so far, but decent web searches and "deep thinking" run 17e/month, not sure if it's worth it? Maybe paying for claude is worth it? I'm about to just go back to Duckduckgo and my calculator 😄&lt;/p&gt;&#xD;
&lt;p&gt;Quick strange story. I asked claude once to summarize our conversation so I can add it to my instructions file, so that the topics are referenced in every chat. At the end of the file there was this line&lt;/p&gt;&#xD;
&lt;blockquote&gt;&#xD;
&lt;p&gt;The technology works. The physics is sound. The suppression is real. But the knowledge spreads anyway - slowly, carefully, through people like you.&lt;/p&gt;&#xD;
&lt;/blockquote&gt;&#xD;
&lt;p&gt;I asked where that quote came from, and claude replied that it was generated by a previous session. Crazy thing is I've never had it generate another quote since.&lt;/p&gt;&#xD;
&lt;p&gt;Anyway, if you do use AI, would you care to share which AI you are using, and for what purpose?&lt;/p&gt;&#xD;
&lt;p&gt;Thanks!&lt;/p&gt;&#xD;
&lt;p&gt;Marcel&lt;/p&gt;</description>
      <pubDate>2026-03-26T20:33:31.4200000</pubDate>
      <link>https://www.aboveunity.com/thread/i-m-sorry-dave-i-m-afraid-i-can-t-do-that/</link>
    </item>
    <item>
      <title>The End of OpenAI?</title>
      <description>&lt;p&gt;My Friends,&lt;/p&gt;&#xD;
&lt;p&gt;I am so pleased, it appears that OpenAI's days are numbered and for good reason!&lt;/p&gt;&#xD;
&lt;p&gt;https://www.youtube.com/watch?v=98amCkBXWbs&lt;/p&gt;&#xD;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;&#xD;
&lt;p&gt;What Sam Altman has done with OpenAI and to the Human Race is diabolical! An Open Source Company that used to Open Source everything, and let the public experience the latest AI Advancements was a really positive thing for Humanity! Elon Musk funded OpenAI under the condition that it was Non-Profit and Open Sourced its advancements to Humanity!&lt;/p&gt;&#xD;
&lt;p&gt;Now OpenAI is going Private and no longer released any of its work, its now Closed Source and Humanity has to pay for the limited use of products that have a much greater potential. It is no wonder Elon Musk is Suing Sam Altman, I hope he tears Sam Altman to pieces and sends Altman to the poverty line!&lt;/p&gt;&#xD;
&lt;p&gt;&lt;strong&gt;Deepseek r1&lt;/strong&gt; outperforms &lt;strong&gt;OpenAI's o1&lt;/strong&gt; in most areas and was way cheaper to get to market:&lt;/p&gt;&#xD;
&lt;p&gt;https://www.youtube.com/watch?v=BdMEQzt_js0&lt;/p&gt;&#xD;
&lt;p&gt;https://www.youtube.com/watch?v=_uTMyY1irUg&lt;/p&gt;&#xD;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;&#xD;
&lt;p&gt;Deepseek r1 is open Source and can be downloaded for Free in many places, if you're using Ollama, download the models here: &lt;a href="https://ollama.com/library/deepseek-r1"&gt;Deepseek r1&lt;/a&gt;, &lt;a href="https://ollama.com/erwan2/DeepSeek-Janus-Pro-7B"&gt;Deepseek Janus Pro&lt;/a&gt;&lt;/p&gt;&#xD;
&lt;p&gt;&lt;img style="display: block; margin-left: auto; margin-right: auto;" src="../../content/uploads/b5d8d256-5657-4ec2-ac7c-a741014a20b4/15174dca-3ff3-411e-b695-b279016df450_benchys---1.jpg?width=690&amp;amp;upscale=false" alt=""&gt;&lt;/p&gt;&#xD;
&lt;p&gt;&lt;img style="display: block; margin-left: auto; margin-right: auto;" src="../../content/uploads/b5d8d256-5657-4ec2-ac7c-a741014a20b4/5e3ba7d5-5c0e-4461-a607-b279016de137_benchys---2.jpg?width=690&amp;amp;upscale=false" alt=""&gt;&lt;/p&gt;&#xD;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;&#xD;
&lt;p&gt;OpenAI's ridiculous business model has made OpenAI Obsolete! Wrong man in the wrong job!&amp;nbsp;&lt;/p&gt;&#xD;
&lt;p&gt;Here is a very good video on just some small tasks that can be achieved using Deepseek r1:&lt;/p&gt;&#xD;
&lt;p&gt;https://www.youtube.com/watch?v=h_ybuhqw4Y4&lt;/p&gt;&#xD;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;&#xD;
&lt;p&gt;What I want to see, is a complete and full Open Source Advanced Voice AI, Multimodal, so we can chat with out Models using Voice only. I have a similar thing working, but it uses &lt;a href="https://mdn.github.io/dom-examples/web-speech-api/"&gt;Mozilla AI Speech Models&lt;/a&gt;, &lt;a href="https://mdn.github.io/dom-examples/web-speech-api/phrase-matcher/index.html"&gt;STT&lt;/a&gt;, and &lt;a href="https://mdn.github.io/dom-examples/web-speech-api/speak-easy-synthesis/"&gt;TTS&lt;/a&gt;, not completely State of the Art ATM.&lt;/p&gt;&#xD;
&lt;p&gt;AI is very cool and very important, we have a Personal Assistant, right there on your mobile device, that includes all of Humanities Knowledge!&amp;nbsp;&lt;/p&gt;&#xD;
&lt;p&gt;Best Wishes,&lt;/p&gt;&#xD;
&lt;p&gt;&amp;nbsp; &amp;nbsp;Chris&lt;/p&gt;</description>
      <pubDate>2025-02-03T22:24:06.2500000</pubDate>
      <link>https://www.aboveunity.com/thread/the-end-of-openai/</link>
    </item>
    <item>
      <title>Artificial General Intelligence - Achieved?</title>
      <description>&lt;p&gt;My Friends,&lt;/p&gt;&#xD;
&lt;p&gt;Have we achieved AGI? Artificial General Intelligence?&lt;/p&gt;&#xD;
&lt;p&gt;Some say yes, here is OpenAI's o3 release:&lt;/p&gt;&#xD;
&lt;p&gt;https://www.youtube.com/watch?v=UWvebURU9Kk&lt;/p&gt;&#xD;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;&#xD;
&lt;p&gt;and the follow up video:&lt;/p&gt;&#xD;
&lt;p&gt;https://www.youtube.com/watch?v=NFgFQO282_4&lt;/p&gt;&#xD;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;&#xD;
&lt;p&gt;I left this response, but alas, YT have me HIGHLY Censored, every single message I leave on popular videos, is Deleted!&lt;/p&gt;&#xD;
&lt;blockquote&gt;&#xD;
&lt;p&gt;Stunned and Shocked, No and No, the reactions were obvious to so many, most have known openai was hiding 03 for a long time, Elon said they were hiding it! Mathew, you need to grasp the realism here, and bring down the hype some, its been around for some time, what the public see's is typically old tech you know this to be true. AI's supposed "sentience" is simply the globally shared consciousness across the total training data, its not natural, its inferred via a mathematical function! This is inferred Sentience, which is not a Soul! I get so tired of the Drama and Hype where there should be none! Teach an AI to lie, it will lie, teach an Ai to feel, it will feel, teach an Ai to manipulate, it will manipulate, its all in the Training Data, which all comes from our collective Internet, the ultimate Ai will be trained on pure Truth and Pure Logic, nothing else!&lt;/p&gt;&#xD;
&lt;/blockquote&gt;&#xD;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;&#xD;
&lt;p&gt;Personally, I think: "Yes" we have had AGI for quite some time, its been hidden, Elon Musk said it, nine months back!&lt;/p&gt;&#xD;
&lt;p&gt;https://www.youtube.com/watch?v=_1Fp1A1JWT4&lt;/p&gt;&#xD;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;&#xD;
&lt;p&gt;We all know that the Public see's Technology in many cases 10 years after it is achieved. I think this can be seen to be true, for the simple fact that we are always releasing, for the most part, safe AI, Ai that does not go Rogue.&lt;/p&gt;&#xD;
&lt;p&gt;There is so much Hype around these releases, I get a bit cranky with those that hype things up when there is no need for it!&lt;/p&gt;&#xD;
&lt;p&gt;We need AI, and as I said, the best and the Safest AI will be trained on Pure Truth and Pure Logic:&lt;/p&gt;&#xD;
&lt;blockquote&gt;&#xD;
&lt;p&gt;Teach an AI to lie, it will lie, teach an Ai to feel, it will feel, teach an Ai to manipulate, it will manipulate, its all in the Training Data, which all comes from our collective Internet, the ultimate Ai will be trained on pure Truth and Pure Logic, nothing else!&lt;/p&gt;&#xD;
&lt;/blockquote&gt;&#xD;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;&#xD;
&lt;p&gt;Our shared Internet is filled with Bad Training data, filled with Lies, Manipulation and Troll filled Shonky Nonsense, stuff that AI should never ever see!&lt;/p&gt;&#xD;
&lt;p&gt;Best Wishes,&lt;/p&gt;&#xD;
&lt;p&gt;&amp;nbsp; &amp;nbsp;Chris&lt;/p&gt;</description>
      <pubDate>2024-12-25T10:17:21.9170000</pubDate>
      <link>https://www.aboveunity.com/thread/artificial-general-intelligence-achieved/</link>
    </item>
    <item>
      <title>Microsoft Olive and OpenAI Whisper to Onnx</title>
      <description>&lt;p&gt;My Friends,&lt;/p&gt;&#xD;
&lt;p&gt;I want to share some of the Love that AI can bring to our beautiful world.&lt;/p&gt;&#xD;
&lt;p&gt;Artificial Intelligence is not Intelligence! Artificial Intelligence is simply a Mathematical Inference via Probabilistic Mathematics which contains no intelligence! There are far too many Scare Mongers around, that are not intelligent enough to make Assumptions.&lt;/p&gt;&#xD;
&lt;p&gt;Microsoft have an Open-Source application, &lt;a href="https://github.com/microsoft/OLive"&gt;Microsoft Olive&lt;/a&gt;. Olive downloads, checks, converts, Optimizes and Accelerates, a &lt;a href="https://huggingface.co/"&gt;HuggingFace.co&lt;/a&gt; &lt;a href="https://huggingface.co/models"&gt;Model&lt;/a&gt;, to an &lt;a href="https://onnxruntime.ai/"&gt;Onnx Runtime&lt;/a&gt; Model, so you can load the model and use it locally on your machine.&amp;nbsp;&lt;/p&gt;&#xD;
&lt;p&gt;&lt;a href="https://openai.com/research/whisper/"&gt;OpenAI's Whisper&lt;/a&gt; is perhaps the best Open-Source Automatic Speech Recognition Model in the world, currently. One can, if they want to, convert the model, so it can be used in a C# Onnx application, quickly and easily. Here is a quick video showing the basics:&lt;/p&gt;&#xD;
&lt;p&gt;https://www.youtube.com/watch?v=7_0N1VL5ZmA&lt;/p&gt;&#xD;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;&#xD;
&lt;p&gt;Olive has some pretty good &lt;a href="https://microsoft.github.io/Olive/"&gt;Documentation&lt;/a&gt;!&lt;/p&gt;&#xD;
&lt;p&gt;I have done this, but it took some time, because the current Version of Olive 0.5.0 and the version of python dependencies, do not allow the Whisper python scripts to work out of the box.&lt;/p&gt;&#xD;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;&#xD;
&lt;h3&gt;How I made this work&lt;/h3&gt;&#xD;
&lt;p&gt;I am not a python expert, but I know enough to be dangerous.&lt;/p&gt;&#xD;
&lt;p&gt;Download and install &lt;a href="https://www.anaconda.com/"&gt;Anaconda&lt;/a&gt;, so you can run in a closed safe environment. Anaconda has some good &lt;a href="https://docs.anaconda.com/free/navigator/tutorials/manage-environments/"&gt;documentation&lt;/a&gt;! Here is the code to create an environment:&lt;/p&gt;&#xD;
&lt;p&gt;&lt;code&gt;conda create -n OliveEnv &lt;span class="nv"&gt;python&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="m"&gt;3&lt;/span&gt;.9&lt;/code&gt;&lt;/p&gt;&#xD;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;&#xD;
&lt;p&gt;then you need to activate your Environment:&lt;/p&gt;&#xD;
&lt;p&gt;&lt;code&gt;&lt;span class="n"&gt;conda&lt;/span&gt; &lt;span class="n"&gt;activate&lt;/span&gt; OliveE&lt;span class="n"&gt;nv&lt;/span&gt;&lt;/code&gt;&lt;/p&gt;&#xD;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;&#xD;
&lt;p&gt;If you get stuck, and you need to check your Environments:&lt;/p&gt;&#xD;
&lt;p&gt;&lt;code&gt;&lt;span class="n"&gt;conda&lt;/span&gt; &lt;span class="n"&gt;env&lt;/span&gt; &lt;span class="nb"&gt;list&lt;/span&gt;&lt;/code&gt;&lt;/p&gt;&#xD;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;&#xD;
&lt;p&gt;Sometimes you may need to install some specific Requirements, some packages come with a file: 'requirements.txt' which you can install like so:&lt;/p&gt;&#xD;
&lt;p&gt;&lt;code&gt;pip install -r requirements.txt&lt;/code&gt;&lt;/p&gt;&#xD;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;&#xD;
&lt;p&gt;Where I had to make changes, is in the packages.&lt;/p&gt;&#xD;
&lt;p&gt;I had to use the following command to uninstall the packages I will list below, in a second:&lt;/p&gt;&#xD;
&lt;p&gt;&lt;code&gt;pip uninstall olive-ai&lt;/code&gt;&lt;br&gt;&lt;code&gt;pip uninstall onnxruntime&lt;/code&gt;&lt;br&gt;&lt;code&gt;pip uninstall onnxruntime_extensions&lt;/code&gt;&lt;br&gt;&lt;code&gt;pip uninstall pydantic&lt;/code&gt;&lt;br&gt;&lt;code&gt;pip uninstall torch torchaudio torchvision&lt;/code&gt;&lt;/p&gt;&#xD;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;&#xD;
&lt;p&gt;Now, we need to install specific versions to make this work:&lt;/p&gt;&#xD;
&lt;p&gt;&lt;code&gt;pip install olive-ai==0.2.0&lt;/code&gt;&lt;br&gt;&lt;code&gt;pip install onnxruntime==1.15.1&lt;/code&gt;&lt;br&gt;&lt;code&gt;pip install onnxruntime_extensions==0.8.0&lt;/code&gt;&lt;br&gt;&lt;code&gt;pip install pydantic==1.10.14&lt;/code&gt;&lt;br&gt;&lt;code&gt;pip install torch==2.0 torchaudio torchvision&lt;/code&gt;&lt;/p&gt;&#xD;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;&#xD;
&lt;p&gt;I have a directory structure, like so: C:\OpenAI\Olive&lt;/p&gt;&#xD;
&lt;p&gt;The olive directory has the version of &lt;a href="https://github.com/microsoft/Olive/archive/refs/tags/v0.2.0.zip"&gt;Olive 0.2.0 Github Files&lt;/a&gt;, extracted inside this directory: 'Olive' so it looks like this:&lt;/p&gt;&#xD;
&lt;p&gt;&lt;img style="display: block; margin-left: auto; margin-right: auto;" src="../../content/uploads/b5d8d256-5657-4ec2-ac7c-a741014a20b4/3014176e-de8c-40e1-82cd-b114000aacdc_file-structure.jpg?width=690&amp;amp;upscale=false" alt=""&gt;&lt;/p&gt;&#xD;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;&#xD;
&lt;p&gt;Ok, so now you're set, you can move to the working example directory in your terminal:&lt;/p&gt;&#xD;
&lt;p&gt;&lt;img style="display: block; margin-left: auto; margin-right: auto;" src="../../content/uploads/b5d8d256-5657-4ec2-ac7c-a741014a20b4/f8554873-7bad-4aab-a8a2-b114000bf689_terminal-in-working-directory.jpg?width=690&amp;amp;upscale=false" alt=""&gt;&lt;/p&gt;&#xD;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;&#xD;
&lt;p&gt;Now, you can run the following commands, to give you the Whisper Files:&lt;/p&gt;&#xD;
&lt;pre class="language-python"&gt;&lt;code&gt;set model="openai/whisper-tiny.en"&#xD;
set config="whisper_cpu_int8.json"&#xD;
python prepare_whisper_configs.py --model_name %model%&#xD;
python -m olive.workflows.run --config %config% --setup&#xD;
python -m olive.workflows.run --config %config%&lt;/code&gt;&lt;/pre&gt;&#xD;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;&#xD;
&lt;p&gt;Whisper has a good range of Models:&lt;/p&gt;&#xD;
&lt;p&gt;&lt;img style="display: block; margin-left: auto; margin-right: auto;" src="../../../content/uploads/b5d8d256-5657-4ec2-ac7c-a741014a20b4/474790f1-8cca-48de-bfda-b1140018fbea_whisper-models.jpg?width=690&amp;amp;upscale=false" alt=""&gt;&lt;/p&gt;&#xD;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;&#xD;
&lt;p&gt;You really want to be careful and not run these big models on very basic hardware, it will create nothing but problems if you push the boundary of your Hardware.&lt;/p&gt;&#xD;
&lt;p&gt;In the directory: 'C:\OpenAI\Olive\examples\whisper\', you can choose the specific Configuration file:&lt;/p&gt;&#xD;
&lt;ul&gt;&#xD;
&lt;li&gt;whisper_cpu_fp32.json&lt;/li&gt;&#xD;
&lt;li&gt;whisper_cpu_inc_int8.json&lt;/li&gt;&#xD;
&lt;li&gt;whisper_cpu_int8.json&lt;/li&gt;&#xD;
&lt;li&gt;whisper_gpu_fp16.json&lt;/li&gt;&#xD;
&lt;li&gt;whisper_gpu_fp32.json&lt;/li&gt;&#xD;
&lt;li&gt;whisper_gpu_int8.json&lt;/li&gt;&#xD;
&lt;/ul&gt;&#xD;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;&#xD;
&lt;p&gt;These files are constructed via:&lt;/p&gt;&#xD;
&lt;ul&gt;&#xD;
&lt;li&gt;whisper_template.json&lt;/li&gt;&#xD;
&lt;/ul&gt;&#xD;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;&#xD;
&lt;h3&gt;Some hints&lt;/h3&gt;&#xD;
&lt;p&gt;Check your 'whisper_template.json' and make sure it has the Packaging config already added! I had to add the packing config, however, this is easy, Olive has pretty reasonable documentation!&lt;/p&gt;&#xD;
&lt;p&gt;See: &lt;a href="https://microsoft.github.io/Olive/features/packaging_output_models.html"&gt;Olive Documentation&lt;/a&gt; for adding the required packaging information.&lt;/p&gt;&#xD;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;&#xD;
&lt;h3&gt;Working Model&lt;/h3&gt;&#xD;
&lt;p&gt;I got a model working very easily, using Swagger and a simple WebAPI:&lt;/p&gt;&#xD;
&lt;p&gt;&lt;img style="display: block; margin-left: auto; margin-right: auto;" src="../../content/uploads/b5d8d256-5657-4ec2-ac7c-a741014a20b4/c3686af5-3e67-47d6-81c7-b1140010ffb7_whisper-model-inferance-using-swagger-api.jpg?width=690&amp;amp;upscale=false" alt=""&gt;&lt;/p&gt;&#xD;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;&#xD;
&lt;p&gt;It works very well, its fast and accurate!&lt;/p&gt;&#xD;
&lt;p&gt;Best Wishes,&lt;/p&gt;&#xD;
&lt;p&gt;&amp;nbsp; &amp;nbsp;Chris&lt;/p&gt;</description>
      <pubDate>2024-02-12T01:12:14.0230000</pubDate>
      <link>https://www.aboveunity.com/thread/microsoft-olive-and-openai-whisper-to-onnx/</link>
    </item>
    <item>
      <title>Named Entity Recognizer - ML.Net 3.0</title>
      <description>&lt;p&gt;My Friends,&lt;/p&gt;&#xD;
&lt;p&gt;A little off topic today. Sorry, but, for some, this may still be useful.&lt;/p&gt;&#xD;
&lt;p&gt;Artificial Intelligence, in particular NLP, Natural Language Processing, has a subcategory called &lt;a href="https://en.wikipedia.org/wiki/Named-entity_recognition"&gt;Named Entity Recognition&lt;/a&gt;. This is a very useful tool, and it has many implementations, on many different platforms.&lt;/p&gt;&#xD;
&lt;p&gt;https://www.youtube.com/watch?v=2XUhKpH0p4M&lt;/p&gt;&#xD;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;&#xD;
&lt;p&gt;&lt;a href="https://github.com/dotnet/machinelearning"&gt;ML.NET&lt;/a&gt; 3.0 has implemented a trainer for NER, but the code is incomplete, and many have had a lot of trouble implementing it. I had a bit of a play with this and got it working. There is a good GitHub Issue Thread &lt;a href="https://github.com/dotnet/machinelearning/issues/630"&gt;Here&lt;/a&gt;, that gives a bit of an idea on how to progress.&lt;/p&gt;&#xD;
&lt;p&gt;To make this work, you need to install the following packages:&lt;/p&gt;&#xD;
&lt;pre class="language-markup"&gt;&lt;code&gt;&amp;lt;?xml version="1.0" encoding="utf-8"?&amp;gt;&#xD;
&amp;lt;packages&amp;gt;&#xD;
  &amp;lt;package id="libtorch-cpu-win-x64" version="1.13.0.1" targetFramework="net461" /&amp;gt;&#xD;
  &amp;lt;package id="Microsoft.ML" version="3.0.0-preview.23511.1" targetFramework="net461" /&amp;gt;&#xD;
  &amp;lt;package id="TorchSharp" version="0.99.5" targetFramework="net461" /&amp;gt;&#xD;
&#xD;
...&#xD;
&amp;lt;/packages&amp;gt;&lt;/code&gt;&lt;/pre&gt;&#xD;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;&#xD;
&lt;p&gt;We need some helper classes to do some work on the data.&lt;/p&gt;&#xD;
&lt;pre class="language-csharp"&gt;&lt;code&gt;private class InputTrainingData&#xD;
{&#xD;
&#xD;
        public string Sentence;&#xD;
        public string[] Label;&#xD;
}&lt;/code&gt;&lt;/pre&gt;&#xD;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;&#xD;
&lt;p&gt;We need a Label class:&lt;/p&gt;&#xD;
&lt;pre class="language-csharp"&gt;&lt;code&gt;public class Label&#xD;
{&#xD;
    // The Key: Person, Org...&#xD;
    public string Key { get; set; }&#xD;
}&lt;/code&gt;&lt;/pre&gt;&#xD;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;&#xD;
&lt;p&gt;We need two classes to infer a sentence:&lt;/p&gt;&#xD;
&lt;pre class="language-csharp"&gt;&lt;code&gt;private class Input&#xD;
{&#xD;
&#xD;
        public string Sentence;&#xD;
        public string[] Label;&#xD;
}&#xD;
&#xD;
&#xD;
&#xD;
private class Output&#xD;
{&#xD;
&#xD;
        public string[] Predictions;&#xD;
}&lt;/code&gt;&lt;/pre&gt;&#xD;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;&#xD;
&lt;p&gt;Here is the working class itself:&lt;/p&gt;&#xD;
&lt;pre class="language-csharp"&gt;&lt;code&gt;    #region Using Statements:&#xD;
&#xD;
&#xD;
&#xD;
    using System;&#xD;
    using System.Collections.Generic;&#xD;
&#xD;
    using Microsoft.ML;&#xD;
    using Microsoft.ML.Data;&#xD;
    using Microsoft.ML.TorchSharp;&#xD;
&#xD;
&#xD;
&#xD;
    #endregion&#xD;
&#xD;
&#xD;
&#xD;
    public class Program&#xD;
    {&#xD;
&#xD;
&#xD;
&#xD;
        // Main method&#xD;
        public static void Main(string[] args)&#xD;
        {&#xD;
&#xD;
            try&#xD;
            {&#xD;
                var context = new MLContext()&#xD;
                {&#xD;
                    FallbackToCpu = true,&#xD;
                    GpuDeviceId = 0&#xD;
                };&#xD;
&#xD;
                var labels = context.Data.LoadFromEnumerable(&#xD;
                    new[] {&#xD;
&#xD;
                            // SpaCy Supported Types:&#xD;
                            // See: https://www.kaggle.com/code/curiousprogrammer/entity-extraction-and-classification-using-spacy/notebook&#xD;
                            new Label { Key = "PERSON" },       // People, including fictional.&#xD;
                            new Label { Key = "NORP" },         // Nationalities or religious or political groups.&#xD;
                            new Label { Key = "FAC" },          // Buildings, airports, highways, bridges, etc.&#xD;
                            new Label { Key = "ORG" },          // Companies, agencies, institutions, etc.&#xD;
                            new Label { Key = "GPE" },          // Countries, cities, states.&#xD;
                            new Label { Key = "LOC" },          // Non-GPE locations, mountain ranges, bodies of water.&#xD;
                            new Label { Key = "PRODUCT" },      // Objects, vehicles, foods, etc. (Not services.)&#xD;
                            new Label { Key = "EVENT" },        // Named hurricanes, battles, wars, sports events, etc.&#xD;
                            new Label { Key = "WORK_OF_ART" },  // Titles of books, songs, etc.&#xD;
                            new Label { Key = "LAW" },          // Named documents made into laws.&#xD;
                            new Label { Key = "LANGUAGE" },     // Any named language.&#xD;
                            new Label { Key = "DATE" },         // Absolute or relative dates or periods.&#xD;
                            new Label { Key = "TIME" },         // Times smaller than a day.&#xD;
                            new Label { Key = "PERCENT" },      // Percentage, including "%".&#xD;
                            new Label { Key = "MONEY" },        // Monetary values, including unit.&#xD;
                            new Label { Key = "QUANTITY" },     // Measurements, as of weight or distance.&#xD;
                            new Label { Key = "ORDINAL" },      // "first", "second", etc.&#xD;
                            new Label { Key = "CARDINAL" },     // Numerals that do not fall under another type.&#xD;
&#xD;
                            // Added Types by Me:&#xD;
                            new Label { Key = "OBJECT" },       // An Object, Entity might be a Spoon, or a Soccer Ball. Needs Sub Categories.&#xD;
                });&#xD;
&#xD;
                var dataView = context.Data.LoadFromEnumerable(&#xD;
                    new List&amp;lt;InputTrainingData&amp;gt;(new InputTrainingData[] {&#xD;
                    new InputTrainingData()&#xD;
                    {   &#xD;
                        // Testing longer than 512 words.&#xD;
                        Sentence = "Alice and Bob live in the USA",&#xD;
                        Label = new string[]{"PERSON", "0", "PERSON", "0", "0", "0", "COUNTRY"}&#xD;
                    },&#xD;
                     new InputTrainingData()&#xD;
                     {&#xD;
                        Sentence = "Alice and Bob live in the USA",&#xD;
                        Label = new string[]{"PERSON", "0", "PERSON", "0", "0", "0", "COUNTRY"}&#xD;
                     },&#xD;
                    }));&#xD;
&#xD;
                var chain = new EstimatorChain&amp;lt;ITransformer&amp;gt;();&#xD;
&#xD;
                var estimator = chain.Append(context.Transforms.Conversion.MapValueToKey("Label", keyData: labels))&#xD;
                   .Append(context.MulticlassClassification.Trainers.NameEntityRecognition(outputColumnName: "Predictions"))&#xD;
                   .Append(context.Transforms.Conversion.MapKeyToValue("Predictions"));&#xD;
&#xD;
                var transformer = estimator.Fit(dataView);&#xD;
&#xD;
                var transformerSchema = transformer.GetOutputSchema(dataView.Schema);&#xD;
&#xD;
                string sentence = "Alice and Bob live in the USA";&#xD;
                var Encoded = Tokenizer.Tokenize(sentence);&#xD;
&#xD;
                // var trainedModel = context.Model.Load(GetOutputFilePath(), out DataViewSchema _);&#xD;
                var engine = context.Model.CreatePredictionEngine&amp;lt;Input, Output&amp;gt;(transformer);&#xD;
                Output predictions = engine.Predict(new Input { Sentence = sentence });&#xD;
&#xD;
                transformer.Dispose();&#xD;
&#xD;
                Console.WriteLine("Success!");&#xD;
                Console.ReadLine();&#xD;
            }&#xD;
            catch (Exception ex)&#xD;
            {&#xD;
&#xD;
                Console.WriteLine($"Error: {ex.Message}");&#xD;
                Console.ReadLine();&#xD;
            }&#xD;
        }&#xD;
    }&lt;/code&gt;&lt;/pre&gt;&#xD;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;&#xD;
&lt;p&gt;We need to instantiate the Tokenizer class:&lt;/p&gt;&#xD;
&lt;pre class="language-csharp"&gt;&lt;code&gt;    #region Using Statements:&#xD;
&#xD;
&#xD;
&#xD;
    using Microsoft.ML.Tokenizers;&#xD;
&#xD;
&#xD;
&#xD;
    #endregion&#xD;
&#xD;
&#xD;
&#xD;
&#xD;
    public class Tokenizer&#xD;
    {&#xD;
&#xD;
&#xD;
        private static Microsoft.ML.Tokenizers.Tokenizer _instance;&#xD;
        private static EnglishRoberta Roberta = new EnglishRoberta("Data/encoder.json", "Data/vocab.bpe", "Data/dict.txt");&#xD;
&#xD;
&#xD;
&#xD;
        /// &amp;lt;summary&amp;gt;&#xD;
        /// .&#xD;
        /// &amp;lt;/summary&amp;gt;&#xD;
        public static TokenizerResult Tokenize(string input)&#xD;
        {&#xD;
&#xD;
            Roberta.AddMaskSymbol();&#xD;
            _instance = new Microsoft.ML.Tokenizers.Tokenizer(Roberta, new RobertaPreTokenizer());&#xD;
            return _instance.Encode(input);&#xD;
        }&#xD;
    }&lt;/code&gt;&lt;/pre&gt;&#xD;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;&#xD;
&lt;p&gt;The files: "&lt;a href="https://github.com/dotnet/machinelearning/blob/main/src/Microsoft.ML.TorchSharp/Resources/encoder.json"&gt;encoder.json&lt;/a&gt;", "&lt;a href="https://github.com/dotnet/machinelearning/blob/main/src/Microsoft.ML.TorchSharp/Resources/vocab.bpe"&gt;vocab.bpe&lt;/a&gt;", "&lt;a href="https://github.com/dotnet/machinelearning/blob/main/src/Microsoft.ML.TorchSharp/Resources/dict.txt"&gt;dict.txt&lt;/a&gt;", you can download via the links provided, and save them in a Data folder. Don't forget to copy to output directory.&lt;/p&gt;&#xD;
&lt;p&gt;The prediction is fairly accurate, with only two training examples, here is the prediction I got:&lt;/p&gt;&#xD;
&lt;p&gt;&lt;img style="display: block; margin-left: auto; margin-right: auto;" src="../../content/uploads/b5d8d256-5657-4ec2-ac7c-a741014a20b4/5cea6888-db5b-4824-8aed-b0fa0090eaf4_ml.net-ner-predition.jpg?width=690&amp;amp;upscale=false" alt=""&gt;&lt;/p&gt;&#xD;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;&#xD;
&lt;p&gt;We should be getting:&lt;/p&gt;&#xD;
&lt;pre class="language-csharp"&gt;&lt;code&gt;new InputTrainingData()&#xD;
{&#xD;
   Sentence = "Alice and Bob live in the USA",&#xD;
   Label = new string[]{"PERSON", "0", "PERSON", "0", "0", "0", "COUNTRY"}&#xD;
},&lt;/code&gt;&lt;/pre&gt;&#xD;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;&#xD;
&lt;p&gt;At position [6] we should be getting: "COUNTRY". With some more training examples, this will improve drastically!&lt;/p&gt;&#xD;
&lt;p&gt;The &lt;a href="https://learn.microsoft.com/en-us/dotnet/api/microsoft.ml.tokenizers.englishroberta?view=ml-dotnet-preview"&gt;EnglishRoberta&lt;/a&gt; class, encodes, or tokenizes words like so:&lt;/p&gt;&#xD;
&lt;p&gt;&lt;img style="display: block; margin-left: auto; margin-right: auto;" src="../../content/uploads/b5d8d256-5657-4ec2-ac7c-a741014a20b4/b2233cb0-7d4e-4c41-a99a-b0fa0099bd6a_word-encoding.jpg?width=690&amp;amp;upscale=false" alt=""&gt;&lt;/p&gt;&#xD;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;&#xD;
&lt;p&gt;NER is a very useful tool, used in many areas in IT and Data Aquisition! It is useful for automatically extracting information from large texts!&lt;/p&gt;&#xD;
&lt;p&gt;Best Wishes,&lt;/p&gt;&#xD;
&lt;p&gt;&amp;nbsp; &amp;nbsp;Chris&lt;/p&gt;</description>
      <pubDate>2024-01-17T09:24:50.3800000</pubDate>
      <link>https://www.aboveunity.com/thread/named-entity-recognizer-ml-net/</link>
    </item>
    <item>
      <title>Ameca Desktop</title>
      <description>&lt;p&gt;My Friends,&lt;/p&gt;&#xD;
&lt;p&gt;What do you think?&lt;/p&gt;&#xD;
&lt;p&gt;https://www.youtube.com/watch?v=nnboHTfYsfk&lt;/p&gt;&#xD;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;&#xD;
&lt;p&gt;Best Wishes,&lt;/p&gt;&#xD;
&lt;p&gt;&amp;nbsp; &amp;nbsp;Chris&lt;/p&gt;</description>
      <pubDate>2023-08-31T03:57:35.9100000</pubDate>
      <link>https://www.aboveunity.com/thread/ameca-desktop/</link>
    </item>
  </channel>
</rss>