strukt/owl

dev-master 2024-08-31 15:24 UTC

This package is not auto-updated.

Last update: 2024-09-21 17:43:49 UTC


README

人工智能包。主要进行文本分析。更多功能即将推出...

用法

情感分析:Vader 分数

$text = "From Oasis' first ever single to the name of Noel and Liam's long-suffering mother, just how well do YOU know the band? Take MailOnline's ultimate quiz";

probe($text);

标签:排名

// use tags function
tags($text); //get all tags

// get to 10 tags above 0.9 ranking
arr(tags($text))->each(fn($k,$v)=>number($v)->gt(0.9)?$k:null)->filter()->values()->yield()

摘要

$text = fs()->cat("news.txt");

summary($text);

高亮

$text = fs()->cat("news.txt");

highlights($text);

致谢