Googling for "Microsoft Windows 10 Cortana®" reveal MANY complaints about memory loss. My experience is 28-33% reported by Task Manager even when Cortana's voice listening and response services are DISABLED / "inactive"! The best advice found to-date has been "remove" or "rename it"!
Usually a BAD workaround! Especially since it was IMPOSSIBLE to do it manually.
Therefore this BATCH file is offered with the warning "EXAMPLE only! Do *NOT* attempt this on any computer. This batch file is ONLY OFFERED as an example of the "IF" statement and batch logic flow."
rem set statusstring="end of %0"
SET /P ISADMIN=Are you RUNNING THIS AS ADMIN (usually from a shortcut 'RUN AS ADMIN') Y/N: =
if /I NOT "%ISADMIN%"=="Y" goto OOPS
rem KLUDGE to SOLVE MEMORY HOG PROBLEM
rem CORTANA is MICROSOFT's AUDIO LISTENER
rem it can take 20-30% or more of RAM
rem can't MANUALLY RENAME or MOVE it because Task Manager RELOADS it
rem SOLUTION: replace MANUAL steps with BATCH commands
rem @echo on
echo step 1 kill SearchUI and rename
IF %ERRORLEVEL% GTR 1 SET ERRSTRING=errlevel%ERRORLEVEL%
for %%x in (ActionUriServer.exe PlacesServer.exe RemindersServer.exe RemindersShareTargetApp.exe SearchUI.exe backgroundTaskHost.exe) do IF EXIST %%x taskkill /T /F /PID %%x
rem taskkill /T /F /PID SearchUI.exe
rem taskkill /T /F /PID backgroundTaskHost.exe
echo step 2 rename folder and/or SearchUI.exe to stop RESTART of Cortana
IF EXIST C:\Windows\SystemApps\Microsoft.Windows.Cortana_cw5n1h2txyewy pushd C:\Windows\SystemApps\Microsoft.Windows.Cortana_cw5n1h2txyewy
IF EXIST SearchUI.exe rename SearchUI.exe zSearchUI.exe
IF EXIST Microsoft.Windows.Cortana_cw5n1h2txyewy move /Y Microsoft.Windows.Cortana_cw5n1h2txyewy Microsoft.Windows.½Cortana_cw5n1h2txyewy
dir /ad Microsoft.Windows.?C*
set statusstring=RUN AS ADMIN (right click on "%0" and Run As Admin)
IF NOT "%ERRSTRING%"=="" echo %ERRSTRING%
ECHO FINISHED BATCH FILE %0