% $Header: /cvsroot/latex-beamer/latex-beamer/solutions/generic-talks/generic-ornate-15min-45min.en.tex,v 1.4 2004/10/07 20:53:08 tantau Exp $

\documentclass{beamer}
%\documentclass[handout]{beamer}
%\usepackage{pgfpages}
%\pgfpagesuselayout{4 on 1}[a4paper,border shrink=5mm,landscape]

% This file is a solution template for:

% - Giving a talk on some subject.
% - The talk is between 15min and 45min long.
% - Style is ornate.



% Copyright 2004 by Till Tantau <tantau@users.sourceforge.net>.
%
% In principle, this file can be redistributed and/or modified under
% the terms of the GNU Public License, version 2.
%
% However, this file is supposed to be a template to be modified
% for your own needs. For this reason, if you use this file as a
% template and not specifically distribute it as part of a another
% package/program, I grant the extra permission to freely copy and
% modify this file as you see fit and even to delete this copyright
% notice. 


\mode<presentation>
{
  \usetheme{Warsaw}
  % or ...

  \setbeamercovered{transparent}
  % or whatever (possibly just delete it)
}


\usepackage[english]{babel}
% or whatever

\usepackage[utf8]{inputenc}
% or whatever

\usepackage{graphicx}

\usepackage{times}
\usepackage[T1]{fontenc}
% Or whatever. Note that the encoding and the font should match. If T1
% does not look nice, try deleting the line with the fontenc.

% Per l'output di source-highlight
% Questo purtroppo non funziona
%\usepackage[usenames,dvipsnames]{color}
% Ergo li copio qui da /usr/share/texmf-tetex/tex/latex/graphics/dvipsnam.def
\DefineNamedColor{named}{Blue}          {cmyk}{1,1,0,0}
\DefineNamedColor{named}{BrickRed}      {cmyk}{0,0.89,0.94,0.28}
\DefineNamedColor{named}{Brown}         {cmyk}{0,0.81,1,0.60}
\DefineNamedColor{named}{ForestGreen}   {cmyk}{0.91,0,0.88,0.12}
\DefineNamedColor{named}{Purple}        {cmyk}{0.45,0.86,0,0}
\DefineNamedColor{named}{Red}           {cmyk}{0,1,1,0}
\DefineNamedColor{named}{Black}         {cmyk}{0,0,0,1}
\DefineNamedColor{named}{RoyalBlue}     {cmyk}{1,0.50,0,0}

\title{\texttt{apt-xapian-index}}
\subtitle{Everything You Always Wanted to Index About Debian Packages, But were Afraid to Ask}

\author
{Enrico Zini \\ \texttt{enrico@debian.org} }

%\institute[ARPA-SIM] % (optional, but mostly needed)
%{
%  Agenzia Regionale Prevenzione e Ambiente (ARPA) \\
%  Servizio Idro-Meteorologico (SIM)
%}

\date[23/02/2008] % (optional)
{23 February 2008}

\subject{Talks}
% This is only inserted into the PDF information catalog. Can be left
% out. 



% If you have a file called "university-logo-filename.xxx", where xxx
% is a graphic format that can be processed by latex or pdflatex,
% resp., then you can add a logo as follows:

% \pgfdeclareimage[height=0.5cm]{university-logo}{university-logo-filename}
% \logo{\pgfuseimage{university-logo}}



% Delete this, if you do not want the table of contents to pop up at
% the beginning of each subsection:
\AtBeginSubsection[]
{
  \begin{frame}<beamer>
    \frametitle{Outline}
    \tableofcontents[currentsection,currentsubsection]
  \end{frame}
}


% If you wish to uncover everything in a step-wise fashion, uncomment
% the following command: 

%\beamerdefaultoverlayspecification{<+->}


\begin{document}

\begin{frame}
  \titlepage
\end{frame}

%\begin{frame}
%  \frametitle{Outline}
%  \tableofcontents
%  % You might wish to add the option [pausesections]
%\end{frame}


% Since this a solution template for a generic talk, very little can
% be said about how it should be structured. However, the talk length
% of between 15min and 45min and the theme suggest that you stick to
% the following rules:  

% - Exactly two or three sections (other than the summary).
% - At *most* three subsections per section.
% - Talk about 30s to 2min per frame. So there should be between about
%   15 and 30 frames, all told.

\section{Introduction}
\subsection{Please help me with the notes}

\begin{frame}
  \frametitle{Please help me with the notes}

  \begin{enumerate}
  \item apt-get install gobby
  \item Run gobby
  \item Connect to the session at \texttt{192.168.42.217}, port \texttt{6522}, password \texttt{enrico}
  \item Join document \texttt{notes.txt}
  \end{enumerate}
\end{frame}

\subsection{Introduction}

\begin{frame}
  \frametitle{The problem}
  
  What I want to see happening

  \begin{itemize}
  \item Build smart interfaces to browse the large Debian archive.
  \end{itemize}

  The first problem I think needs solving:

  \begin{itemize}
  \item The only fast package index we have at the moment is \texttt{APT}
  \item The task of the \texttt{APT} index is to solve dependencies
  \item \texttt{APT} shouldn't be expanded (bloated) to do much more
  \item Solution: create another index to complement \texttt{APT}
  \end{itemize}
\end{frame}

\begin{frame}
  \frametitle{What the new index should have}

  \begin{itemize}
  \item Fast full text searches
  \item Fast tag searches
  \item Extensible, to accomodate new ideas for data to index
  \end{itemize}
\end{frame}

\section{The solution}

\subsection{A tour of \texttt{apt-xapian-index}}

\begin{frame}
  \frametitle{A tour of \texttt{apt-xapian-index}}
  \framesubtitle{The technology}

  \begin{itemize}
  \item Sits in \texttt{/var/lib/apt-xapian/index}
  \item Based on \texttt{Xapian}
    \begin{itemize}
    \item Indexes text as well as numbers and dates
    \item Decent bindings in all sorts of languages
    \item Stretchable and abusable by great lengths
    \end{itemize}
  \item Self documented in \texttt{/var/lib/apt-xapian-index/README}
  \end{itemize}
\end{frame}

\begin{frame}
  \frametitle{A tour of \texttt{apt-xapian-index}}
  \framesubtitle{Indexing}

  \begin{itemize}
  \item Done by \texttt{/usr/sbin/update-apt-xapian-index}
  \item Can be run interactively
  \item Runs in a weekly cron job
  \item Packages can inject extra data by adding plugins in \texttt{/usr/share/apt-xapian-index/plugins}
  \end{itemize}
\end{frame}

\begin{frame}
  \frametitle{A tour of \texttt{apt-xapian-index}}
  \framesubtitle{Searching}

  \begin{itemize}
  \item You just need the plain Xapian API
  \item \texttt{/var/lib/apt-xapian-index/README} documents the index layout
  \end{itemize}
\end{frame}

\begin{frame}
  \frametitle{Tools using it}

  \begin{itemize}
  \item \texttt{goplay} (\texttt{golearn}, \texttt{goadmin}, \dots{})
  \item \texttt{debtags.debian.net} (just started)
  \end{itemize}
\end{frame}

\subsection{Code examples}

\begin{frame}
  %\includegraphicscopyright[width=9.5cm]{beamerexample-lecture-pic6.jpg}
  %{Copyright Till Tantau, Low Resultion}

  %\frametitle{A tour of \texttt{apt-xapian-index}}
  %\framesubtitle{Searching}

  %\begin{itemize}
  %\item You just need the plain Xapian API
  %\item \texttt{/var/lib/apt-xapian-index/README} documents the index layout
  %\end{itemize}

  This page is sneakily left blank to divert your attention elsewhere.
\end{frame}

\section{Interesting bits still to figure out}
\section{HELP!}

\begin{frame}
  \frametitle{Getting more data into the system}
  \framesubtitle{My proposal}

  \begin{itemize}
  \item One package per dataset to get
  \item Ship a copy of the dataset in the package, to use if everything fails
  \item A tool that can be run to fetch the data, or
  \item A plugin system to fetch the data using a single tool instead?
  \item Download new versions using a cron job
  \item Provide the data somewhere under /var
  \item Add an apt-xapian-index plugin to index it
  \end{itemize}

  For example: popcon, bts statistics, iterating.org
\end{frame}

\begin{frame}
  \frametitle{More indexing ideas}
  \framesubtitle{Debian specific stemming}

  \begin{itemize}
  \item ``lib\em{foo}'' becomes ``library'' and ``foo''; ``deb\em{foo}'' becomes ``debian'' and ``foo''
  \item ``cvsdelta'', ``cvsgraph'', ``gnomecatalog'', ``gnomeradio'', ``gnu\em{something}'' (but not ``gnustep''), ``kde\em{something}''...
  \item More generally, how to index ``Rindfleischetikettierungsüberwachungsaufgabenübertragungsgesetz''?
  \item How to provide the same stemming algorithm at query time?
  \item Compensate with improved descriptions?
  \end{itemize}
\end{frame}

\begin{frame}
  \frametitle{More indexing ideas}
  \framesubtitle{What else to index?}

  \begin{itemize}
  \item popcon
  \item bts statistics
  \item iterating.com
  \item more ideas?
  \end{itemize}
\end{frame}

\begin{frame}
  \frametitle{i18n}
  \framesubtitle{How about searching translated descriptions?}

  \begin{itemize}
  \item Xapian already supports stemming for many languages
  \item Is it useful, with such short descriptions?
  \item One index per language?
  \item How about disk space, and indexing time?
  \end{itemize}
\end{frame}

\begin{frame}
  \frametitle{Index update}
  \framesubtitle{Can it be improved?}

  \begin{itemize}
  \item Incremental updates
    \begin{itemize}
    \item Need to track what's new after an \emph{apt-get update}
    \item Increases index size
    \end{itemize}
  \item Suid update script to run goplay right after installing it
  \end{itemize}
\end{frame}

\end{document}
