init
Some checks failed
Tests / PHP 8.2 (push) Has been cancelled
Tests / PHP 8.3 (push) Has been cancelled
Tests / PHP 8.4 (push) Has been cancelled

This commit is contained in:
jiangdong.cheng
2026-02-11 17:28:36 +08:00
parent dcb82557c7
commit aa16c9f8c2
162 changed files with 22333 additions and 0 deletions

View File

@@ -0,0 +1,110 @@
@extends('layouts.site')
@section('page_class', 'page-models')
@section('title', 'AI 模型推荐 - AIWeb')
@section('meta_description', '按模态、部署方式与评分维度筛选 AI 模型,快速完成选型。')
@section('canonical', route('models.index'))
@section('content')
<section class="module-hero">
<div class="position-relative">
<span class="hero-chip"><i class="bi bi-cpu"></i> 模型推荐</span>
<h1 class="h2 fw-bold mt-2">AI 模型推荐榜</h1>
<p class="hero-subtext">效果优先,结合成本与速度做多维评估,帮助你更稳地选模型。</p>
</div>
</section>
<div class="module-grid">
<div>
<section class="block-card p-3 p-lg-4 mb-3">
<form method="get" action="{{ route('models.index') }}" class="row g-2 align-items-end">
<div class="col-md-5">
<label class="form-label" for="modelSearchKeyword">关键词</label>
<input id="modelSearchKeyword" class="form-control" type="search" name="q" value="{{ $filters['q'] ?? '' }}" placeholder="例如:长上下文、多模态…" aria-label="按关键词搜索模型" autocomplete="off" spellcheck="false">
</div>
<div class="col-md-3">
<label class="form-label" for="modelModality">模态</label>
<select id="modelModality" class="form-select" name="modality">
<option value="">全部</option>
@foreach(['text' => '文本', 'multimodal' => '多模态', 'image' => '图像', 'audio' => '音频'] as $value => $label)
<option value="{{ $value }}" @selected(($filters['modality'] ?? '') === $value)>{{ $label }}</option>
@endforeach
</select>
</div>
<div class="col-md-3">
<label class="form-label" for="modelDeployment">部署</label>
<select id="modelDeployment" class="form-select" name="deployment">
<option value="">全部</option>
@foreach(['api' => 'API', 'self_hosted' => '私有部署', 'hybrid' => '混合'] as $value => $label)
<option value="{{ $value }}" @selected(($filters['deployment'] ?? '') === $value)>{{ $label }}</option>
@endforeach
</select>
</div>
<div class="col-md-1 d-grid">
<button class="btn btn-primary" type="submit" aria-label="筛选模型"><i class="bi bi-search me-1" aria-hidden="true"></i>筛选</button>
</div>
</form>
</section>
<section class="row g-3">
@forelse($items as $model)
<div class="col-lg-6">
<article class="entry-item h-100">
<div class="d-flex justify-content-between align-items-start mb-2">
<div>
<a class="h5 text-decoration-none mb-0 d-inline-block" href="{{ route('models.show', $model->slug) }}">{{ $model->name }}</a>
<div class="small text-muted-soft">{{ $model->provider ?: '未知供应商' }} · {{ $model->modality }}</div>
</div>
<span class="chip">总分 {{ $model->total_score }}</span>
</div>
<p class="text-muted-soft small line-clamp-2 mb-3">{{ $model->summary }}</p>
<div class="mb-2 small">效果 {{ $model->effectiveness_score }}</div>
<div class="metric-bar mb-2"><div class="metric-fill bg-primary" style="width:{{ $model->effectiveness_score }}%"></div></div>
<div class="mb-2 small">价格 {{ $model->price_score }}</div>
<div class="metric-bar mb-2"><div class="metric-fill bg-success" style="width:{{ $model->price_score }}%"></div></div>
<div class="mb-2 small">速度 {{ $model->speed_score }}</div>
<div class="metric-bar mb-3"><div class="metric-fill bg-warning" style="width:{{ $model->speed_score }}%"></div></div>
<div class="d-flex justify-content-between align-items-center">
<small class="text-muted-soft">更新于 {{ $model->updated_at?->format('Y-m-d') }}</small>
<a class="btn btn-sm btn-outline-primary" href="{{ route('models.show', $model->slug) }}">详情</a>
</div>
</article>
</div>
@empty
<div class="col-12"><div class="block-card p-4 text-center text-muted-soft">暂无符合条件的模型</div></div>
@endforelse
</section>
<div class="mt-3">{{ $items->links() }}</div>
</div>
<aside>
<section class="block-card p-3 mb-3">
<h3 class="section-title mb-3">工具补充</h3>
@forelse($sidebarTools as $tool)
<article class="pb-2 mb-2 border-bottom" style="border-color:var(--line)!important;">
<a class="fw-semibold text-decoration-none" href="{{ route('tools.show', $tool->slug) }}">{{ $tool->name }}</a>
<div class="small text-muted-soft">{{ $tool->pricing_type }} · {{ $tool->has_api ? 'API' : 'No API' }}</div>
</article>
@empty
<p class="text-muted-soft small mb-0">暂无工具</p>
@endforelse
</section>
<section class="block-card p-3">
<h3 class="section-title mb-3">最新资讯</h3>
@forelse($sidebarNews as $news)
<article class="pb-2 mb-2 border-bottom" style="border-color:var(--line)!important;">
<a class="fw-semibold text-decoration-none" href="{{ route('news.show', $news->slug) }}">{{ $news->title }}</a>
<div class="small text-muted-soft">{{ $news->published_at?->format('m-d H:i') }}</div>
</article>
@empty
<p class="text-muted-soft small mb-0">暂无资讯</p>
@endforelse
</section>
</aside>
</div>
@endsection

View File

@@ -0,0 +1,93 @@
@extends('layouts.site')
@section('page_class', 'page-models')
@section('title', $item->seo_title ?: $item->name.' - AI模型详情')
@section('meta_description', $item->seo_description ?: $item->summary)
@section('canonical', $item->canonical_url ?: route('models.show', $item->slug))
@section('head')
<script type="application/ld+json">
{!! json_encode([
'@context' => 'https://schema.org',
'@type' => 'SoftwareApplication',
'name' => $item->name,
'description' => $item->summary,
'applicationCategory' => 'AI Model',
], JSON_UNESCAPED_UNICODE|JSON_UNESCAPED_SLASHES|JSON_PRETTY_PRINT) !!}
</script>
@endsection
@section('content')
<section class="module-hero">
<div class="position-relative">
<span class="hero-chip mb-2">{{ $item->provider ?: '模型推荐' }}</span>
<h1 class="h2 fw-bold mb-2">{{ $item->h1 ?: $item->name }}</h1>
<p class="hero-subtext">{{ $item->summary }}</p>
</div>
</section>
@if($showRiskNotice)
<div class="alert alert-warning" role="alert">免责声明:高风险领域内容仅供学习参考,不构成专业建议。</div>
@endif
<div class="module-grid">
<div>
<section class="surface-card p-3 p-lg-4 mb-3">
<div class="d-flex justify-content-between align-items-center mb-2">
<h2 class="section-title mb-0"><i class="bi bi-card-text text-primary"></i> 模型介绍</h2>
<span class="chip">总分 {{ $item->total_score }}</span>
</div>
<div class="md-content">{{ $item->description ?: $item->summary }}</div>
</section>
<section class="surface-card p-3 p-lg-4 mb-3">
<h2 class="section-title mb-3"><i class="bi bi-bar-chart-line text-primary"></i> 评分维度</h2>
<div class="mb-2 small">效果 {{ $item->effectiveness_score }}</div>
<div class="metric-bar mb-2"><div class="metric-fill bg-primary" style="width:{{ $item->effectiveness_score }}%"></div></div>
<div class="mb-2 small">价格 {{ $item->price_score }}</div>
<div class="metric-bar mb-2"><div class="metric-fill bg-success" style="width:{{ $item->price_score }}%"></div></div>
<div class="mb-2 small">速度 {{ $item->speed_score }}</div>
<div class="metric-bar"><div class="metric-fill bg-warning" style="width:{{ $item->speed_score }}%"></div></div>
</section>
@if($relatedModels->isNotEmpty())
<section class="surface-card p-3 p-lg-4">
<h2 class="section-title mb-3"><i class="bi bi-diagram-3 text-primary"></i> 同类模型</h2>
<div class="row g-3">
@foreach($relatedModels as $model)
<div class="col-md-6">
<article class="entry-item h-100">
<a class="fw-semibold text-decoration-none" href="{{ route('models.show', $model->slug) }}">{{ $model->name }}</a>
<p class="small text-muted-soft line-clamp-2 mb-2">{{ $model->summary }}</p>
<span class="chip">总分 {{ $model->total_score }}</span>
</article>
</div>
@endforeach
</div>
</section>
@endif
</div>
<aside>
<section class="surface-card p-3 p-lg-4 mb-3">
<h3 class="section-title mb-3">模型信息</h3>
<ul class="list-unstyled small mb-0">
<li class="mb-2">提供方:<strong>{{ $item->provider ?: '未知' }}</strong></li>
<li class="mb-2">模态:<strong>{{ $item->modality }}</strong></li>
<li class="mb-2">部署:<strong>{{ $item->deployment_mode }}</strong></li>
<li class="mb-2">来源可信度:<strong>{{ $item->source_level?->label() ?? '未知' }}</strong></li>
<li>最后校验:<strong>{{ $item->last_verified_at?->format('Y-m-d') ?? '未记录' }}</strong></li>
</ul>
</section>
@if($item->is_stale)
<div class="alert alert-warning mb-3">
该模型信息可能过期。
@if($item->alternative)
可参考替代模型:<a href="{{ route('models.show', $item->alternative->slug) }}">{{ $item->alternative->name }}</a>
@endif
</div>
@endif
</aside>
</div>
@endsection