diff --git a/daemon/table/cs-policy.hpp b/daemon/table/cs-policy.hpp
index de4c89c..748a45b 100644
--- a/daemon/table/cs-policy.hpp
+++ b/daemon/table/cs-policy.hpp
@@ -33,7 +33,7 @@
 class Cs;
 
 /**
- * \brief Represents a CS replacement policy
+ * \brief Represents a CS replacement policy.
  */
 class Policy : noncopyable
 {
@@ -47,13 +47,15 @@
     BOOST_VERIFY(r.second);
   }
 
-  /** \return a cs::Policy identified by \p policyName,
-   *          or nullptr if \p policyName is unknown
+  /**
+   * \brief Returns a cs::Policy identified by \p policyName,
+   *        or nullptr if \p policyName is unknown.
    */
   static unique_ptr<Policy>
   create(const std::string& policyName);
 
-  /** \return a list of available policy names
+  /**
+   * \brief Returns a list of available policy names.
    */
   static std::set<std::string>
   getPolicyNames();
@@ -63,36 +65,39 @@
   ~Policy() = default;
 
   const std::string&
-  getName() const
+  getName() const noexcept
   {
     return m_policyName;
   }
 
-  /** \brief gets cs
+  /**
+   * \brief Returns a pointer to the associated CS instance.
    */
   Cs*
-  getCs() const
+  getCs() const noexcept
   {
     return m_cs;
   }
 
-  /** \brief sets cs
+  /**
+   * \brief Sets the associated CS instance.
    */
   void
-  setCs(Cs* cs)
+  setCs(Cs* cs) noexcept
   {
     m_cs = cs;
   }
 
-  /** \brief gets hard limit (in number of entries)
+  /**
+   * \brief Gets hard limit (in number of entries).
    */
   size_t
-  getLimit() const
+  getLimit() const noexcept
   {
     return m_limit;
   }
 
-  /** \brief sets hard limit (in number of entries)
+  /** \brief Sets hard limit (in number of entries).
    *  \post getLimit() == nMaxEntries
    *  \post cs.size() <= getLimit()
    *
@@ -102,19 +107,19 @@
   setLimit(size_t nMaxEntries);
 
 public:
-  /** \brief a reference to an CS entry
-   *  \note operator< of EntryRef compares the Data name enclosed in the Entry.
+  /** \brief A reference to a CS entry.
+   *  \note `operator<` of EntryRef compares the Data name enclosed in the Entry.
    */
   using EntryRef = Table::const_iterator;
 
-  /** \brief emits when an entry is being evicted
+  /** \brief %Signal emitted when an entry is being evicted.
    *
    *  A policy implementation should emit this signal to cause CS to erase an entry from its index.
    *  CS should connect to this signal and erase the entry upon signal emission.
    */
   signal::Signal<Policy, EntryRef> beforeEvict;
 
-  /** \brief invoked by CS after a new entry is inserted
+  /** \brief Invoked by CS after a new entry is inserted.
    *  \post cs.size() <= getLimit()
    *
    *  The policy may evict entries if necessary.
@@ -123,20 +128,20 @@
   void
   afterInsert(EntryRef i);
 
-  /** \brief invoked by CS after an existing entry is refreshed by same Data
+  /** \brief Invoked by CS after an existing entry is refreshed by same Data.
    *
    *  The policy may witness this refresh to make better eviction decisions in the future.
    */
   void
   afterRefresh(EntryRef i);
 
-  /** \brief invoked by CS before an entry is erased due to management command
+  /** \brief Invoked by CS before an entry is erased due to management command.
    *  \warning CS must not invoke this method if an entry is erased due to eviction.
    */
   void
   beforeErase(EntryRef i);
 
-  /** \brief invoked by CS before an entry is used to match a lookup
+  /** \brief Invoked by CS before an entry is used to match a lookup.
    *
    *  The policy may witness this usage to make better eviction decisions in the future.
    */
@@ -144,7 +149,7 @@
   beforeUse(EntryRef i);
 
 protected:
-  /** \brief invoked after a new entry is created in CS
+  /** \brief Invoked after a new entry is created in CS.
    *
    *  When overridden in a subclass, a policy implementation should decide whether to accept \p i.
    *  If \p i is accepted, it should be inserted into a cleanup index.
@@ -155,7 +160,7 @@
   virtual void
   doAfterInsert(EntryRef i) = 0;
 
-  /** \brief invoked after an existing entry is refreshed by same Data
+  /** \brief Invoked after an existing entry is refreshed by same Data.
    *
    *  When overridden in a subclass, a policy implementation may witness this operation
    *  and adjust its cleanup index.
@@ -163,7 +168,7 @@
   virtual void
   doAfterRefresh(EntryRef i) = 0;
 
-  /** \brief invoked before an entry is erased due to management command
+  /** \brief Invoked before an entry is erased due to management command.
    *  \note This will not be invoked for an entry being evicted by policy.
    *
    *  When overridden in a subclass, a policy implementation should erase \p i
@@ -172,7 +177,7 @@
   virtual void
   doBeforeErase(EntryRef i) = 0;
 
-  /** \brief invoked before an entry is used to match a lookup
+  /** \brief Invoked before an entry is used to match a lookup.
    *
    *  When overridden in a subclass, a policy implementation may witness this operation
    *  and adjust its cleanup index.
@@ -180,7 +185,7 @@
   virtual void
   doBeforeUse(EntryRef i) = 0;
 
-  /** \brief evicts zero or more entries
+  /** \brief Evicts zero or more entries.
    *  \post CS size does not exceed hard limit
    */
   virtual void
@@ -207,7 +212,7 @@
 
 } // namespace nfd::cs
 
-/** \brief registers a CS policy
+/** \brief Registers a CS policy.
  *  \param P a subclass of nfd::cs::Policy
  */
 #define NFD_REGISTER_CS_POLICY(P)                      \
